Skip to content

Commit

Permalink
Merge pull request #236 from datalayer-externals/fix/marked_loading
Browse files Browse the repository at this point in the history
Copy marked.umd.js to marked.js and revert loading
  • Loading branch information
ericsnekbytes authored Mar 29, 2023
2 parents f237e24 + d40b723 commit 04ddbef
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion nbclassic/static/base/js/markdown.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ define([
'base/js/utils',
'base/js/mathjaxutils',
'base/js/security',
'components/marked/lib/marked.umd',
'components/marked/lib/marked',
'codemirror/lib/codemirror',
], function($, utils, mathjaxutils, security, marked, CodeMirror){
"use strict";
Expand Down
2 changes: 1 addition & 1 deletion nbclassic/static/base/js/namespace.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ define(function(){
// tree
jglobal('SessionList','tree/js/sessionlist');

Jupyter.version = "0.5.3";
Jupyter.version = "0.6.0.dev0";
Jupyter._target = '_blank';

return Jupyter;
Expand Down
2 changes: 1 addition & 1 deletion nbclassic/static/notebook/js/shortcuteditor.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ define([
"jquery",
"notebook/js/quickhelp",
"base/js/dialog",
"components/marked/lib/marked.umd"
"components/marked/lib/marked"
], function (
$,
QH,
Expand Down
2 changes: 1 addition & 1 deletion nbclassic/static/tree/js/notebooklist.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ define([
'base/js/keyboard',
'moment',
'bidi/bidi',
'components/marked/lib/marked.umd'
'components/marked/lib/marked'
], function($, IPython, utils, i18n, dialog, events, keyboard, moment, bidi, marked) {
"use strict";

Expand Down
4 changes: 3 additions & 1 deletion setupbase.py
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ def find_package_data():
pjoin(components, "jquery-ui", "dist", "jquery-ui.min.js"),
pjoin(components, "jquery-ui", "dist", "themes", "smoothness", "jquery-ui.min.css"),
pjoin(components, "jquery-ui", "dist", "themes", "smoothness", "images", "*"),
pjoin(components, "marked", "lib", "marked.umd.js"),
pjoin(components, "marked", "lib", "marked.js"),
pjoin(components, "react", "react.production.min.js"),
pjoin(components, "react", "react-dom.production.min.js"),
pjoin(components, "requirejs", "require.js"),
Expand Down Expand Up @@ -417,6 +417,8 @@ def run(self):
cwd=repo_root,
env=env
)
# Copy the UMD files to their JavaScript equivalent to ensure correct loading.
shutil.copyfile(pjoin(self.bower_dir, "marked", "lib", "marked.umd.js"), pjoin(self.bower_dir, "marked", "lib", "marked.js"))
except OSError as e:
print("Failed to run bower: %s" % e, file=sys.stderr)
print("You can install js dependencies with `npm install`", file=sys.stderr)
Expand Down

0 comments on commit 04ddbef

Please sign in to comment.