Responsive NavBar with Tailwind
I would appreciate if anyone can point me to an online resource that can help me integrate a responsive NavBar using Tailwind.
3 Replies
Do you know css?
Tailwind is just the same as pure CSS, just with pre-defined utility classes.
As with most things, there are many ways to do it. It can depend on if you want to use JS or not, how you want the responsiveness to work etc.
Whilst not a tutorial, I have a Tailwind responsive nav demo here https://codepen.io/cbolson/pen/QWPRKzv.
Note, this does not use JS as I opted to use a hidden checkbox for this one. This may mean that it is possibly missing some accessibility details such as holding the nav visibility "state". However it might help you as a starting point.
Thanks so much for this. I have gotten a hang of it. I'm using Nextjs for development and I would have used React Bootstrap but I don't want to install a new package because of just one solution. Your example was helpful by the way.