This script acts like auto-render for KaTeX and render mathmatical text in Typst form based on wypst.
git clone https://github.com/Lambdaris/typst-auto-render.git
cd typst-auto-render
npm install
npm run build
<script src="typst-auto-render.js"></script>
<script>
document.addEventListener("DOMContentLoaded", function () {
renderMathInElement(document.body, {
throwOnError: false
});
});
</script>
It has same interface with KaTeX auto render and the options
is much like.
Note customization for delimeters is not supported and mathmatical expressions are wrapped in same way as Typst. Users could write "\$" to type an literal "$" (might be "\\$" in markdown being converted to html).