1. 在命令行运行:pip install jupyter_contrib_nbextensions

2. 确保jupyter notebook已被关闭,在命令行运行:jupyter contrib nbextension install --user --skip-running-check

3. 启动jupyter notebook,选项栏出现Nbextensions,点击它,出现如图:

jupyter notebook目录导航

勾选Table of Contents

4. 打开一个ipynb,如图

jupyter notebook目录导航

点击红圈图标。

感谢caoqi95的简书https://www.jianshu.com/p/7687c6bec65e, 照Ta的讲解进行,完成。

相关文章: