From cd213b20908467a9d4acba0e848ed96d8c5b0315 Mon Sep 17 00:00:00 2001
From: Bas Nijholt <basnijholt@gmail.com>
Date: Thu, 18 Oct 2018 00:48:22 +0200
Subject: [PATCH] simplify holoviews js and css

---
 docs/source/conf.py | 31 ++++---------------------------
 1 file changed, 4 insertions(+), 27 deletions(-)

diff --git a/docs/source/conf.py b/docs/source/conf.py
index a8ee2bd2..53b22a81 100644
--- a/docs/source/conf.py
+++ b/docs/source/conf.py
@@ -128,35 +128,12 @@ intersphinx_mapping = {
 }
 
 
-# -- Add Holoviews js and css ------------------------------------------------
-
 def setup(app):
     from holoviews.plotting import Renderer
-
-    hv_js, hv_css = Renderer.html_assets(
-        extras=False, backends=[], script=True)
-
-    fname_css = 'holoviews.css'
-    fname_js = 'holoviews.js'
-    static_dir = 'source/_static'
-
-    os.makedirs(static_dir, exist_ok=True)
-
-    with open(f'{static_dir}/{fname_css}', 'w') as f:
-        hv_css = hv_css.split('<style>')[1].replace('</style>', '')
-        f.write(hv_css)
-
-    with open(f'{static_dir}/{fname_js}', 'w') as f:
-        f.write(hv_js)
-
-    app.add_stylesheet(fname_css)
-    app.add_javascript(fname_js)
-
-    dependencies = {**Renderer.core_dependencies, **Renderer.extra_dependencies}
-    for name, type_url in dependencies.items():
-        if name in ['bootstrap']:
-            continue
-
+    dependencies = {**Renderer.core_dependencies,
+                    **Renderer.extra_dependencies}
+    for name in ['jQueryUI', 'jQuery', 'require']:
+        type_url = dependencies[name]
         for url in type_url.get('js', []):
             app.add_javascript(url)
         for url in type_url.get('css', []):
-- 
GitLab