Html components and bootstrap

Hello everyone,

I’m new on using Dash and i’m currently on developping a web app with this framework.

I asked myself this question:

To realize the front-end part of my application, can I use “dash-html-components” and bootstrap (with classname) as if I wanted to realize the front-end of an ordinary website?
If so, this will mean that in general, indentation errors will be related to HTML/CSS language and not to Dash?

Last question, I saw “Dash-Bootstrap-Components” and its features like navbar. If I understand correctly it’s a module that makes it easier to indent the web application, but I can do the same thing with “dash-html-components” and bootstrap?

Thank you and have a good evening.


Hey @Duaran

Yes, there’s a pretty close correspondence between HTML elements and dash-html-components, so you can certainly use a HTML template as a guide when building the layout of your apps, setting className and style as necessary throughout.

Anything you can do with just HTML and CSS you don’t necessarily need dash-bootstrap-components for, such as rows and columns, listgroups, cards etc. However, any Bootstrap components that rely on some JavaScript might be harder to get working, particularly if they use jQuery under the hood which doesn’t play so nicely with React. Furthermore you won’t be easily able to control the properties of the Bootstrap components with Dash callbacks, dash-bootstrap-components will let you e.g. open and close modals etc. based on callbacks, so will integrate a bit better with the other interactivity in your app.

Hello @tcbegley ,

Thank you for your answer ! I,now, understand more about the usefulness of dash-bootstrap!

Have a nice day

1 Like