Dash और Plotly के साथ डैशबोर्ड बनाना
Alex Scriven
Data Scientist
dash.html कॉम्पोनेंट्स उपयोग करता है.H1() है.Div() है<div>
<div style=
"background-color: red;
width:250; height:250;">
</div>
<div style=
"background-color: lightblue;
width:250; height:250;">
<h1>This box</h1>
</div>
</div>
.Br() = नई लाइन ब्रेक.Img() = इमेज जोड़ें
.Ul() \ .Ol() और .Li() = लिस्ट बनाएँ.Ul() अनऑर्डर्ड लिस्ट के लिए (बुलेट-पॉइंट्स, जैसे ये!).Ol() ऑर्डर्ड लिस्ट के लिए (नंबर-पॉइंट्स).Li() हर लिस्ट आइटम के लिए
app.layout = [html.Img(src='www.website.com/logo.png'), html.H1("Our Sales Dashboard")]

टेक्स्ट कंटेंट सेट और फॉर्मैट करें
.P() या .Span() = साधारण टेक्स्ट जोड़ें.P() या .Span() की लिस्ट).B() = कुछ टेक्स्ट को Bold करें.I() = कुछ टेक्स्ट को Italic करें
कुछ जटिल फॉर्मैटिंग:
app.layout = [ html.H1("Our Sales Dashboard"),html.Span(children=[f"Prepared: {datetime.now().date()}"," by ", html.B("Jessie Parker, "),html.I("Data Scientist")])]

$$
app.layout = [
html.H1("Our Sales Dashboard"),
html.Span(children=[
f"Prepared: {datetime.now().date()}",
html.Br(),
" by ", html.B("Jessie Parker, "),
html.Br(),
html.I("Data Scientist")])
]

Dash और Plotly के साथ डैशबोर्ड बनाना