Users can install the current version of ipywidgets with pip or conda.
pip install ipywidgets
jupyter nbextension enable --py widgetsnbextensionWhen using virtualenv and working in
an activated virtual environment, the --sys-prefix option may be required
to enable the extension and keep the environment isolated (i.e.
jupyter nbextension enable --py widgetsnbextension --sys-prefix).
conda install -c conda-forge ipywidgetsInstalling ipywidgets with conda will also enable the extension for you.
To install the JupyterLab extension you also need to run the below command in a terminal which requires that you have nodejs installed.
jupyter labextension install @jupyter-widgets/jupyterlab-managerNote: A clean reinstall of the JupyterLab extension can be done by first
running the jupyter lab clean command which will remove the staging and
static directories from the lab directory. The location of the lab directory
can be queried by executing the command jupyter lab path in your terminal.