Skip to content

Commit 7ba1198

Browse files
committed
Fix example links
1 parent 1fce659 commit 7ba1198

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

docs/examples/__init__.py

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import os
12
import re
23
from pathlib import Path
34

@@ -14,7 +15,7 @@
1415
EXAMPLES = HERE / "vendor"
1516
TEMPLATES = HERE.parent / "templates"
1617

17-
GITHUB_EXAMPLES = Path(
18+
GITHUB_EXAMPLES = (
1819
"https://github.com/"
1920
"facultyai/dash-bootstrap-components/blob/master/examples/"
2021
)
@@ -87,13 +88,15 @@ def register_apps():
8788
iris_app,
8889
"iris",
8990
(EXAMPLES / "iris.py").read_text(),
90-
str(GITHUB_EXAMPLES / "gallery/iris-kmeans/app.py"),
91+
os.path.join(GITHUB_EXAMPLES, "gallery/iris-kmeans/app.py"),
9192
)
9293
git_app_ = build_app_from_example(
9394
git_app,
9495
"graphs-in-tabs",
9596
(EXAMPLES / "graphs_in_tabs.py").read_text(),
96-
str(GITHUB_EXAMPLES / "advanced-component-usage/graphs_in_tabs.py"),
97+
os.path.join(
98+
GITHUB_EXAMPLES, "advanced-component-usage/graphs_in_tabs.py"
99+
),
97100
)
98101

99102
# need to do a bit of hackery to make sure the links of the multi page app
@@ -109,7 +112,7 @@ def register_apps():
109112
sidebar_app,
110113
"simple-sidebar",
111114
sidebar_source,
112-
str(GITHUB_EXAMPLES / "multi-page-apps/simple_sidebar.py"),
115+
os.path.join(GITHUB_EXAMPLES, "multi-page-apps/simple_sidebar.py"),
113116
show_warning=True,
114117
)
115118

0 commit comments

Comments
 (0)