DEV Community

Discussion on: Tailwind CSS static navbar with shadow on scroll for Vue applications

Collapse
 
codervtwo profile image
John Samuel • Edited

Great post! I'm using Vue/Nuxt, Tailwind and Firebase to build some hobbyist projects and I love it. I like having so much control and the ability to write the html and "css" at the same time in the same place.

Anyway, I have a newbie question. When I fix the nav bar like this, how do I prevent it from covering the top part of the element below (my nuxt element) ?

Collapse
 
chipd profile image
Chris Dermody

I usually add a padding/margin to the top of the body element so that all content is pushed down a little. Hope that helps