Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

export Notebook in pdf #173

Open
Mad31 opened this issue Jul 26, 2023 · 5 comments
Open

export Notebook in pdf #173

Mad31 opened this issue Jul 26, 2023 · 5 comments
Labels
enhancement New feature or request

Comments

@Mad31
Copy link

Mad31 commented Jul 26, 2023

Proposal

When i try to export Notebook to HTML or to pdf for example, whe lost all the myst-formatting of the Notebook. I know that the mystV2 works with the markdown renderer but with the Notebook export, it will be fantastic.

Additional notes

  • jupyterlab-myst v1.2.0 enabled OK
  • jupyterlab : 3.6.5
@Mad31 Mad31 added the enhancement New feature or request label Jul 26, 2023
@jonathan-s
Copy link

I've tried using jupyter-myst 2.1.0, and this issue is still persisting there when trying to export to pdf.

@agoose77
Copy link
Collaborator

Jupyter Lab's exporting feature uses nbconvert under the hood. This extension is only concerned with the frontend experience, and doesn't touch that part of Jupyter.

If you want to generate HTML or PDF MyST, I'd recommend looking at our new CLI tools based upon the same technology that powers jupyterlab-myst, i.e. https://mystmd.org/
There is also our existing Sphinx-based stack, which powers (among other things) documentation (e.g. https://awkward-array.org/doc/main/user-guide/how-to-convert-numpy.html)

@aydemiro
Copy link

@agoose77 How does one use myst CLI to export a jupyter notebook to HTML? I cannot see it in the documentation. There is a suggestion to add a frontmatter cell at the top for exporting but HTML is not an option. I have no issues building the notebook and rendering using myst.

@agoose77
Copy link
Collaborator

@aydemiro
Copy link

aydemiro commented Jun 11, 2024

Thanks for the speedy response! The html created this way looks fairly terrible when I open it locally (below).
It looks good if I start a server npx serve as suggested but I still cannot save an easily sharable html file from the server. I am looking into jupyter-book to see if that can help. It seems like jb has a build html option that generate a more standard html.

Screenshot 2024-06-11 at 1 52 53 PM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants