Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion js/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"watch": "webpack --watch"
},
"jupyterlab": {
"extension": "src/labplugin"
"extension": "src/lab_plugin"
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The file was renamed to lab_extension not lab_plugin. Am I missing something?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, I was ;). I fixed it in a follow up.

},
"devDependencies": {
"fs-extra": "^4.0.2",
Expand Down
17 changes: 6 additions & 11 deletions js/src/index.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,7 @@
// Entry point for the notebook bundle containing custom model definitions.
//
// Setup notebook base URL
//
// Some static assets may be required by the custom widget javascript. The base
// url for the notebook is not known at build time and is therefore computed
// dynamically.
__webpack_public_path__ = document.querySelector('body').getAttribute('data-base-url') + 'nbextensions/jupyter-matplotlib/';
var MPLCanvasModel = require('./mpl_widget').MPLCanvasModel;
var MPLCanvasView = require('./mpl_widget').MPLCanvasView;

// Export widget models and views, and the npm package version number.
module.exports = require('./mpl_widget.js');
module.exports['version'] = require('../package.json').version;
module.exports = {
MPLCanvasModel: MPLCanvasModel,
MPLCanvasView: MPLCanvasView
}
File renamed without changes.
File renamed without changes.
12 changes: 12 additions & 0 deletions js/src/nb_index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
// Entry point for the notebook bundle containing custom model definitions.
//
// Setup notebook base URL
//
// Some static assets may be required by the custom widget javascript. The base
// url for the notebook is not known at build time and is therefore computed
// dynamically.
__webpack_public_path__ = document.querySelector('body').getAttribute('data-base-url') + 'nbextensions/jupyter-matplotlib/';

// Export widget models and views, and the npm package version number.
module.exports = require('./mpl_widget.js');
module.exports['version'] = require('../package.json').version;
4 changes: 2 additions & 2 deletions js/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ module.exports = [
// "load_ipython_extension" function which is required for any notebook
// extension.
//
entry: './src/extension.js',
entry: './src/nb_extension.js',
output: {
filename: 'extension.js',
path: staticDir,
Expand All @@ -37,7 +37,7 @@ module.exports = [
// This bundle contains the implementation for the custom widget views and
// models.
//
entry: './src/index.js',
entry: './src/nb_index.js',
output: {
filename: 'index.js',
path: staticDir,
Expand Down