Skip to content

Latest commit

 

History

History
52 lines (34 loc) · 784 Bytes

README.md

File metadata and controls

52 lines (34 loc) · 784 Bytes

Dash Bootstrap

安裝

pip install dash-bootstrap-components

Bootstrap 有各種主題可以直接套用(theme)

import dash
import dash_bootstrap_components as dbc

app = dash.Dash(
    external_stylesheets=[dbc.themes.BOOTSTRAP] #套用theme
)

app.layout = dbc.Alert(
    "Hello, Bootstrap!", className="m-5"
)

if __name__ == "__main__":
    app.run_server()

import dash
import dash_bootstrap_components as dbc

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

app.layout = dbc.Alert(
    "Hello, Bootstrap!", className="m-5"
)

if __name__ == "__main__":
    app.run_server()