Skip to content
This repository has been archived by the owner on Apr 16, 2023. It is now read-only.

Enter-tainer/typst-ws

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

typst-ws

Preview your typst file in instant.

To use this in vscode, take a look at https://github.com/Enter-tainer/typst-preview-vscode

demo.mp4

Why not typst watch ?

The bottleneck is the pdf viewer. typst watch is not fast enough to preview the pdf file in real time. (You may also choose faster pdf viewer like Zathura.)

How?

We follow the similar approach as typst.app, by rendering the doc to framebuffers. And send them through websocket to the browser.

Note: Most of the code is directly copy-pasted from https://github.com/typst/typst/tree/main/cli

Usage

Install from source:

cargo run --release -- watch ./test.typ

Or download prebuilt binary: https://nightly.link/Enter-tainer/typst-ws/workflows/build/master

Then open index.html in your browser.

See also

About

preview your typst document in instant

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published