-
Notifications
You must be signed in to change notification settings - Fork 30
Expand file tree
/
Copy pathdash_html_gen.py
More file actions
44 lines (37 loc) · 1.12 KB
/
dash_html_gen.py
File metadata and controls
44 lines (37 loc) · 1.12 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
from dash import Dash, html, dcc
import plotly.express as px
external_stylesheets = ["https://codepen.io/chriddyp/pen/bWLwgP.css"]
app = Dash(__name__, external_stylesheets=external_stylesheets)
app.layout = html.Div(
[
html.H1("Simple HTML Only Site"),
html.H2("TalkPython Training"),
html.Div(
[
html.P("Annual Fuel Cost Plot",
className="my-p-class",
id="my-p-id")
],
style={
"color": "green",
"fontSize": 18
},
),
dcc.Markdown("""
#### Dash Supports Markdown
You can write simple text and format it with markup like
**bold text** and *italics*, [links](http://commonmark.org/help).
You can also use:
* lists
* inline `code` snippets
* and more
"""),
],
style={
"margin-left": "25px",
"width": "55%",
"backgroundColor": "lightgray"
},
)
if __name__ == "__main__":
app.run_server(debug=True)