Previewing Markdown, PDF, and Math Formula in JupyterLab
By defaults, this function is disabled. The preview function has cross-site scripting (XSS) security risks. To ensure system security, do not open untrusted files. Exercise caution when using these functions and ensure that the file source is reliable.
Enabling/Disabling the Preview Function
- Open the terminal of the notebook instance. For details, see Common Functions of JupyterLab.
- Run the commands below to enable or disable the preview function.
- Enable the PDF file preview function.
$CONDA_BIN/jupyter labextension enable @jupyterlab/pdf-extension
- Disable the PDF file preview function.
$CONDA_BIN/jupyter labextension disable @jupyterlab/pdf-extension
- Enable the Markdown file preview function.
$CONDA_BIN/jupyter labextension enable @jupyterlab/markdownviewer-extension:plugin
- Disable the Markdown file preview function.
$CONDA_BIN/jupyter labextension disable @jupyterlab/markdownviewer-extension:plugin
- Enable the math formula preview function.
$CONDA_BIN/jupyter labextension enable @jupyterlab/mathjax-extension:plugin $CONDA_BIN/jupyter labextension enable @jupyterlab/mathjax2-extension:plugin
- Disable the math formula preview function.
$CONDA_BIN/jupyter labextension disable @jupyterlab/mathjax-extension:plugin $CONDA_BIN/jupyter labextension disable @jupyterlab/mathjax2-extension:plugin
- Enable the PDF file preview function.
- After enabling or disabling the preview function, refresh the web page.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot