jupyterjupyter-lab

How do I launch jupyter lab with the dark theme enabled by default?


The answer to this question points out that the "JupyterLab Dark" theme is now available as part of a vanilla jupyter-lab install.

How can I configure jupyter-lab so that it launches with this theme already applied on the first launch, so I don't have to manually select it every time I launch my jupyter docker container?


Solution

  • Put this in ~/.jupyterlab/user-settings/@jupyterlab/apputils-extension/themes.jupyterlab-settings

    {
        "theme": "JupyerLab Dark"
    }
    

    In the Dockerfile this might look like:

    RUN mkdir -p ~/.jupyterlab/user-settings/@jupyterlab/apputils-extension/ && \
        echo '{ "theme":"JupyterLab Dark" }' > themes.jupyterlab-settings