Skip to content

Commit 8411e2f

Browse files
committed
switch to different method for adding js and css files to docs; hopefully fixes the missing default stylesheets on RTD (pydatagh-35)
1 parent 18f6c5b commit 8411e2f

1 file changed

Lines changed: 7 additions & 10 deletions

File tree

doc/conf.py

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,13 @@
6363
'ipython_directive', 'ipython_console_highlighting',
6464
]
6565

66+
# Undocumented trick: if we def setup here in conf.py, it gets called just
67+
# like an extension's setup function.
68+
def setup(app):
69+
app.add_javascript("show-code.js")
70+
app.add_javascript("facebox.js")
71+
app.add_stylesheet("facebox.css")
72+
6673
# Add any paths that contain templates here, relative to this directory.
6774
templates_path = ['_templates']
6875

@@ -148,16 +155,6 @@
148155
# so a file named "default.css" will overwrite the builtin "default.css".
149156
html_static_path = ['_static']
150157

151-
# Hack: the first three of these are the default script_files, because the
152-
# settings here actually *override* the defaults.
153-
html_context = {"script_files": ["_static/jquery.js",
154-
"_static/underscore.js",
155-
"_static/doctools.js",
156-
"_static/show-code.js",
157-
"_static/facebox.js",
158-
],
159-
"css_files": ["_static/facebox.css"]}
160-
161158
# If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
162159
# using the given strftime format.
163160
#html_last_updated_fmt = '%b %d, %Y'

0 commit comments

Comments
 (0)