Box is not accepting percentages as sizes
See original GitHub issueIn the examples/API is written:
<Box width="50%">X</Box>
but when trying it, I get this error:
Warning: Failed prop type: Invalid prop `width` of type `string` supplied to `Box`, expected `number`.
Is it not supported anymore?
Issue Analytics
- State:
- Created 4 years ago
- Comments:5 (4 by maintainers)
Top Results From Across the Web
Why do percentage-width-sized flex box items not properly ...
I am looking into this at the moment, but your first mistake is . flex { flex: 1 } . This attribute is...
Read more >box-sizing - CSS: Cascading Style Sheets - MDN Web Docs
The box-sizing CSS property sets how the total width and height of an element is calculated.
Read more >CSS Box Sizing Module Level 3 - W3C
Sizes specified on sizing properties as <length-percentage> represent the box's visually-apparent sizes, including the borders/padding (but not ...
Read more >Changes on CSS Grid Layout in percentages and indefinite ...
The simple answer is that a definite size is a size that you can calculate without taking into account the contents of the...
Read more >Percentages: Height & Width - Learn CSS: Responsive Design
Percentages are often used to size box-model values, like width and height, padding, border, and margins. They can also be used to set...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
It is supported, I just didn’t publish a new release. I’m planning to publish one tomorrow.
New release is out - https://github.com/vadimdemedes/ink/releases/tag/v2.1.0 🎆