![html - Css "width:fit-content;" property doesn't work well. Parent element has this property calculates its width smaller than its content - Stack Overflow html - Css "width:fit-content;" property doesn't work well. Parent element has this property calculates its width smaller than its content - Stack Overflow](https://i.stack.imgur.com/v1vzy.png)
html - Css "width:fit-content;" property doesn't work well. Parent element has this property calculates its width smaller than its content - Stack Overflow
![Fit-content not working as expected - HTML & CSS - SitePoint Forums | Web Development & Design Community Fit-content not working as expected - HTML & CSS - SitePoint Forums | Web Development & Design Community](https://global.discourse-cdn.com/sitepoint/original/3X/f/d/fd1aaa0f9bfafa7da0d68e8d65c961725823c410.jpeg)
Fit-content not working as expected - HTML & CSS - SitePoint Forums | Web Development & Design Community
![javascript - A good alternative to this use of CSS "width: fit-content" in a responsive layout? - Stack Overflow javascript - A good alternative to this use of CSS "width: fit-content" in a responsive layout? - Stack Overflow](https://i.stack.imgur.com/itycL.png)