Creating an entry point for notebook manager extensions

- Firing app_initialized.DashboardApp event when loaded the notebook manager
- Updating tree.html template to load nbextensions through custom.js
pull/37/head
Jean-Christophe Jaskula 12 years ago
parent 8c60671cb8
commit 9c2c680e8f

@ -12,7 +12,7 @@
*
* Same thing with `profile/static/custom/custom.css` to inject custom css into the notebook.
*
* Example :
* __Example 1:__
*
* Create a custom button in toolbar that execute `%qtconsole` in kernel
* and hence open a qtconsole attached to the same kernel as the current notebook
@ -30,7 +30,16 @@
* ]);
* });
*
* Example :
* __Example 2:__
*
* At the completion of the dashboard loading, load an unofficial javascript extension
* that is installed in profile/static/custom/
*
* $([IPython.events]).on('app_initialized.DashboardApp', function(){
* require(['custom/unofficial_extension.js'])
* });
*
* __Example 3:__
*
* Use `jQuery.getScript(url [, success(script, textStatus, jqXHR)] );`
* to load custom script into the notebook.

@ -70,7 +70,8 @@ $(document).ready(function () {
enable_autorefresh();
IPython.page.show();
$([IPython.events]).trigger('app_initialized.DashboardApp');
// bound the upload method to the on change of the file select list
$("#alternate_upload").change(function (event){
IPython.notebook_list.handleFilesUpload(event,'form');

Loading…
Cancel
Save