The development of extensions requires a certain set of tools that have been set up to work together. While it is possible to install these tools systemwide, it is generally good practice to use a virtual environment manager such as Virtualenv or Anaconda. If Miniconda hasn't been installed, follow the instructions at https://docs.conda.io/en/latest/miniconda.html# before continuing.
Besides JupyterLab and Node.js, you will also need to install cookiecutter. This is a tool that creates a project based on a template. The Jupyter organization have produced four (+1) templates that work with cookiecutter and are available on GitHub (https://github.com/jupyterlab?q=cookiecutter). They are JavaScript and TypeScript templates for generic extensions and TypeScript templates for mime renderers and themes (the JavaScript mime renderer has been archived).
To create a new environment for developing JupyterLab extensions, run the following command:
conda create -n jupyterlab-ext -c conda-forge --override-channels nodejs jupyterlab cookiecutter
Use the following command to activate the environment:
conda activate jupyterlab-ext
Each time the Anaconda prompt is closed, you will have to run this command to reactivate the development environment.