- The power of types from TypeScript project.
- Rich code completion and code inspection thanks to types.
- TypeScript 4.1 support.
- REPL console support.
Screenshots: Code inspection (Shift-Tab) and completion (Tab)
Try tslab without installing it
If nbviewer is down, please view the notebooks on GitHub instead.
- Install Node.js (LTS or Current)
- Install Python3.x
- tslab works with Jupyter on Python2.7.
- But I recommend you to use Jupyter on Python3.x because the latest Jupyter does not support Python2.7
- Install the latest version of JupyterLab or Jupyter Notebook
npm install -g tslab
Please make sure
tslab command is available in your terminal.
tslab install --version
tslab to your Jupyter environment.
tslab install [--python=python3]
By default, tslab is registered with
python3 in unix-like system and
python in Windows.
If Jupyter is installed with a different Python in your system, please specify the python command with
After you run
tslab install, please check two kernels (jslab and tslab) are installed properly to jupyter.
$ jupyter kernelspec list Available kernels: jslab /usr/local/google/home/yunabe/.local/share/jupyter/kernels/jslab tslab /usr/local/google/home/yunabe/.local/share/jupyter/kernels/tslab
Usage: JupyterLab and Jupyter Notebook
After you register
# JupyterLab # `--port=` to change the port to accept connections. # `--ip=0.0.0.0` to accept external connections. jupyter lab [--port=8888] [--ip=0.0.0.0] # Jupyter Notebook jupyter notebook
In Jupyter, you can complete code by pressing
Tab and show tooltips by pressing
Shift + Tab.
Usage: REPL console
You can also use tslab and Jupyter as an interactive console (REPL).
To use tslab as REPL, please run
jupyter console with
jupyter console --kernel=tslab