Help with displaying two graphs in 1 row, 2 columns

Hey @ElChico

Did you link to a Bootstrap stylesheet? If not then the rows and columns won’t work. dash-bootstrap-components uses Bootstrap CSS for styling and layout, but this is not included automatically with the Python package, you have to link it yourself. The reason for not including it automatically is because Bootstrap is highly customisable, there are many free themes online and people compile their own versions. We wanted to allow people to use dash-bootstrap-components with any of these sheets.

Fortunately linking is very simple. The easiest way is do add the following when you initialise your app object

app = dash.Dash(external_stylesheets=[dbc.themes.BOOTSTRAP])

This will link the standard Bootstrap stylesheet and the rows and columns should work. As I mentioned above, this will make some stylistic changes to the fonts and spacing etc. If you don’t want those, you can use the Bootstrap grid css on its own:

app = dash.Dash(external_stylesheets=[
    "https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap-grid.min.css"
])

or as I mentioned in my previous post you can download the file directly from GitHub and place it in a folder called assets in the same directory as your main python file. Dash will automatically detect and link any css you put in this folder. See the Dash docs for details.

If you already did this, or if you try it and it still doesn’t work let me know.