简体   繁体   English

如何有效编辑jupyter Notebook的javascript文件?

[英]How can I effectively edit jupyter notebook's javascript files?

So notebook's js files are all stored in python_packages_folder/notebook/static/notebook/js however when I edit them, no change happens and checking the loaded js files on the browser I find them look like as if they were not edited. 因此,笔记本的js文件都存储在python_packages_folder/notebook/static/notebook/js但是当我对其进行编辑时,未发生任何变化,并且在浏览器中检查了已加载的js文件后,我发现它们看起来好像没有被编辑过。 Why does this happen? 为什么会这样?

I had the same problem when I want to temporarily test some use cases. 当我想临时测试一些用例时,我遇到了同样的问题。 I hacked it by doing the following: 我通过执行以下操作来入侵它:

cd python_packages_folder/notebook/static/notebook/js
mv main.min.js main.min.js.bak
cp main.js min.min.js

Then you restart your jupyter and open one notebook you will see all the original (not-minified) javascript files. 然后重新启动jupyter并打开一个笔记本,您将看到所有原始(未缩小)的javascript文件。 They all come with an ?v=timestamp suffix, indicating they will be reloaded when you modify them. 它们都带有?v=timestamp后缀,表示您在修改它们时将重新加载它们。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM