We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
app.add_javascript
1 parent b0f41a1 commit 2db3551Copy full SHA for 2db3551
sphinx_tabs/tabs.py
@@ -4,7 +4,7 @@
4
import json
5
import os
6
import posixpath
7
-import sphinx
+
8
from docutils import nodes
9
from docutils.parsers.rst import Directive, directives
10
from pkg_resources import resource_filename
@@ -347,11 +347,7 @@ def setup(app):
347
if "add_script_file" in dir(app):
348
app.add_script_file(path)
349
else:
350
- # check sphinx version for backward compatibility
351
- if sphinx.version_info >= (3, 0):
352
- app.add_js_file(path)
353
- else:
354
- app.add_javascript(path)
+ app.add_js_file(path)
355
app.connect("html-page-context", update_context)
356
app.connect("build-finished", copy_assets)
357
0 commit comments