2

I would like to use custom .css style file for my jupyter notebook inside jupyterHub. I placed the custom.css file inside ~.jupyter/custom/custom.css and /opt/conda/lib/python3.6/site-packages/notebook/static/custom and neither of them works. Any idea how to force custom css style when using DockerSpawner?

4
  • This directory ~/.jupyter/custom/custom.css, did mean on jupyterhub container or jupyter-notebook (user) container. cutsom folder must be on user container. Commented Feb 11, 2019 at 12:15
  • @saurssaurav it is on the user container Commented Feb 11, 2019 at 12:32
  • I had my custom folder in user container like ~/.jupyter/custom/custom.css . And its running perfectly taking all custom css. Did you check inside container if custom folder exist ? Commented Feb 11, 2019 at 12:40
  • @saurssaurav I will check it once again later and let you know Commented Feb 11, 2019 at 15:32

2 Answers 2

2

Probably too late to help OP, but leaving here for future dwellers:

I placed my custom.css and custom.js in /usr/local/lib/python3.6/dist-packages/notebook/static/custom/ and it worked perfectly.

NB I don't use conda, and I use the default (Local) spawner instead of DockerSpawner (if that's relevant).

Sign up to request clarification or add additional context in comments.

Comments

0

The location for "Anaconda3 , Windows10, Everyone to Access" is c:\programData\Anaconda3\Lib\site-packages\notebook\static\custom\custom.css

We may look for ~/.jupyter/custom/custom.css . if it does not exist, we can create one. However, since it is just created, we need to restart the notebook to be effective. Afterwards, we may simply change the contents of the file anytime without restarting the notebook.

1 Comment

Please add further details to expand on your answer, such as working code or documentation citations.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.