Can I pull from a page in a PDF and show it?

Hi so I am still learning Typst. In markdown I was able to pick up pages in a pdf and then display them by including a LaTex command.

In my YAML I would put:

---
header-includes:
- \usepackage{pdfpages}
---

Then in the Markdown I write:

\includepdf[pages=2,frame=true,scale=.9]{Correspondence with Lehigh County Attorneys.pdf}

This pulls in page 2 of a PDF named “Correspondence with Lehigh County Attorneys.pdf}” and displays it at 90% scale. Is there a way to do something similar in Typst?

hi, the package muchpdf supports inserting pdf page ranges and single pages, and with scale.

Typst itself does not yet support inserting pdfs as images (but the webapp version of Typst will automatically convert pdfs to svg.)

1 Like

That package rasterizes some things in the PDF pages and doesn’t work on big files, because it’s very hacky, but should work just fine for some people.

See also

As this seems to be a duplicate and the information in this thread is also available in that other thread, I’ll close this topic. Feel free to flag my reply/message me if you think this is an error.