Gistd: GitHub instantly share typst document

Made a simple website that renders typst documents on github: GitHub - Myriad-Dreamin/gistd: Instantly share typst documents on git and other network storage.

Usage

Assuming that you have a GitHub link for example:

https://github.com/typst/templates/blob/main/charged-ieee/template/main.typ

Simply replace the github.com with gistd.myriad-dreamin.com:

https://gistd.myriad-dreamin.com/typst/templates/blob/main/charged-ieee/template/main.typ

Sample

https://gistd.myriad-dreamin.com/typst/templates/blob/main/charged-ieee/template/main.typ

Future Improvement

  • Support compiler version
  • Support loading fonts from Google Fonts

16 Likes

Nice!

Can this be hosted on a company’s own server?

The export to PDF is downloading something, but it doesn’t seem to be in PDF format. Is this coming, or a bug?

Also, how do you plan to license this software?

I added Apache 2.0 LICENSE to gistd. This is aligned to typst.

2 Likes

Can this be hosted on a company’s own server?

We could add docker container to help deploy. It should be easy, because gistd is a simple single-page app. The github action exhibits how to deploy gistd: gistd/.github/workflows/gh-pages.yml at 2407f0c0dc2c0bf1b59454077cd668264a1fcb57 · Myriad-Dreamin/gistd · GitHub

The export to PDF is downloading something, but it doesn’t seem to be in PDF format. Is this coming, or a bug?

Could you elaborate? I cannot get with the “downlading something.”

When clicking the Export to PDF button on the top right, a PDF file gets downloaded by the browser but that file is not valid.

2 Likes

template.typ uses charged-ieee, which specifies TeX Gyre Termes, which must not be available as it’s using Libertinus. I can tell by the cool “p” in the italic “Typst GmbH”.

I know Google Fonts is planned, but I think if the system had at least the fonts that were on typst.app, that would be better. Or if it showed warnings when fonts weren’t available.

Since Google Fonts has modified, less feature-rich versions of fonts, this creates an issue. I wish we had a public repository of fonts with all of their versions that Typst could automatically download to a cache and use. If users could specify an exact version of a font in their source, the document would come out the same way every time.