JupyterLab extensions are valid npm packages written in JavaScript or TypeScript (a superset of JavaScript aimed at large applications). While all extensions are installed in the same manner, JupyterLab distinguishes between three different types of extensions:
- Theme extensions, which add a new color scheme
- Mime renderers, which render file types inside the application
- Application extensions, the most general extension that extends the functionality of the application
The JupyterLab site provides the complete process for developing a sample picture of the day extension: https://jupyterlab.readthedocs.io/en/stable/developer/extension_tutorial.html.
The main steps include the following:
- Setting up your development environment
- Creating an extension project
- Adding a widget (or theme or mime handler, depending on the type of extension)
- Fine-tuning
- Publishing
Development, in general, is an iterative process with lots of trial and error. It is good practice to use a version control system such as Git or Mercurial. Sites such as GitHub, GitLab, and Bitbucket offer free repository hosting and a way to share code.
This tutorial is intended to help you develop a JupyterLab extension and as such, instructions on using source control will not be covered.