Center Text Horizontally And Vertically With Tailwind CSS 3
January 2022
With tailwind, this will put the content centered in the middle of the page both vertically and horizontally
this is in the middle
(Of course, you'll want to use className for something like Nextjs)
Here's an example with three blocks of content stacked over each other with the contents of each centered:
Need an idea for a programming project?
Here ya go...
refreshIdea()}
>
Get another idea
)
}TODO: Refine that example some
end of line