Prevent line breaks with CSS
Published in
2 min readMay 30, 2021
— css trick in a React component🧚
Recently I encountered an interesting problem, let’s say, there are some list items to display using the basic React code like below 👇
✨ Notice those items should be side by side ( inline and of course without any line breaks ) like the result below👇
I wrote some simple css: ✏️
And the Result was 💥
See the line breaks? Ugly enough…
🤞 Here comes my simple solution: