π Hello! Congrats on completing the challenge.
Tailwind actually comes with preset font-sizes, I'm curious why not use those instead? e.g. text-xs
which is 0.75rem (12px), text-sm
which is 0.875rem; (14px), etc?
Alternatively, font-size could be overwrote with your own set of sizes via tailwind.config.js
.
Also, one tiny trick that could help with writing lesser code is to use the gap
(flex and grid) or the space-y
and space-x
utilities. They help to add gaps or margin between child elements so you wouldn't need to keep adding margins to every child element π
Hope this helps and happy coding~
Marked as helpful
@BrnCosta
Posted
@Milleus Hello Dave!
This was my first time using tailwind, so I'm not used to all his features. But you're absolutely right! In my next solution, I'll use it.
Thanks for your comment and tips, I appreciate it!