Project

General

Profile

Building a Bootstrap 4 navbar in Wt

Added by Michelle Dupuis almost 5 years ago

I'm new to Wt, and come from developing web apps using Bootstrap 4. As my first app (ok, I already did a hello world) I want to build a navbar. There is a great example Bootstrap 4 navbar here:

[[[https://getbootstrap.com/docs/4.0/components/navbar/]]]

and I'm wondering how best to recreate this in Wt 4. I see the navigation bar widget in Wt here:

[[[https://webtoolkit.eu/widgets/navigation/navigation-bar]]]

But that doesn't make use of Bootstrap 4 that I can see. I want to be able to style the background, buttons, etc. and it should have a very Bootstrap look to it. I could create an Wt XML template with the bootstrap code it in, and then bind buttons to the menu items using Wt but that feels wrong. If I do it using the navbar example in Wt then it doesn't take advantage of Bootstrap. There is something inbetween I'm missing. Can someone offer advice?