HNHacker News
TopNewBestAskShowJobs

yaoke259

181 karma · joined April 12, 2025

submissionscomments
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
will do
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
MDX is not secure by default, you'd be executing arbitrary JS code potentially sent by untrustworthy sources, which is advised against in the MDX website.
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
I'm in Sydney and will be sleeping, will answer new questions in the morning!
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
real
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
yes, that was! and I totally understand what you mean. Whilst building this I've often wondered if other people have totally unrelated use cases for it
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
These are all great points too! so in your opinion should I still keep the {id, value} encapsulated event system, it offers less control, but a minimal api shape for easy handling at the application level
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
yes like MDX, but not compiled :)
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
this actually uses web components under the hood! the dsl is more secure and easier to write (at least in my opinion). For v2 I'll make the whole design/architecture more polished and web-component oriented, possibly with some sort of verifier/editor support???
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
Yes fallback markup is what I meant, and yes, it would not be super useful if JS is entirely disabled. I figured custom elements would be good since they can encapsulate state and styling, allowing for slightly more sophisticated behaviour compared to raw dom elements
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
am going to do a rewrite for v2. For some reason custom elements and astro don't play well with each other for me. I believe this issue does not happen on Sveltekit, Next etc. but this project is very young so bear with me
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
I'm just too lazy lol, only wrote raw even listeners when I had no other choice ahahahaha. somehow my brain just did not make the connection
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
I'm already looking at a v2 implementation as some others have correctly pointed this out. Since I'm already relying on customElements and web components, I should make that first class and change the framework implementations into thin wrappers. V2 will be pure js custom elements which can fall back to native html. wrappers will be even more lightweight. Hopefully this design is a strict win
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
yes, very interesting area to be explored further
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
thanks!
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
thanks!
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
fixed
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
fixed
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
Thanks for the questions and super valuable feedback! To be totally honest, I came from a Svelte/Framework background and just did not deeply consider/realise you can create a pure dom version and event handling with just plain js. It's definitely a valid point that I'll take into consideration into designing the next version. Currently it does seem a bit overengineered since the React, Vue and Svelte implementations are actually all wrappers over web components, and still potentially offer some (potential) advantages in advanced state management which I have not yet explored. I'll definitely look into this more deeply.
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
I have fixed the home page bug, apologies
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
This happened after I turned the demo site into Astro to demo all the frameworks at once. For some reason it messes with the hydration of the site, will keep debugging...
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
I suppose a vanilla js version is possible? I'll need to look into this
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
Seems like some people are confused by the design decisions of using React/Svelte/Vue and using it at runtime. The use case I had in mind was LLM interaction, which you can try in the Chat Demo (running a real llm btw!). LLMs require secure, runtime, and minimal DSL to generate interactivity, hence markdown-ui.
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
so runtime use cases like LLMs can be supported, in the Chat example you can interact with a real llm!
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
I designed it this way to be more markdown like, and without support for styling
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
html does not allow for event handling, this allows for secure listening of the events at runtime, which afaik is not possible with html
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
thanks :)
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
the reason I made it is that mdxjs (afaik) only works with a build step and locks the user into React, and you are still technically running code sent by the LLM, rather than a more secure static JSON like object.
yaoke259··on Show HN: Turn Markdown into React/Svelte/Vue UI at runtime, zero build step
Svelte, React and Vue allow for easier event handling, at least that was my rationale, is it possible to achieve the same with html?
yaoke259··on Show HN: Markdown-UI, interactive UI inside Markdown for LLMs
interesting, I was not aware of this project. the UI side of my project is definitely not as polished haha
← PreviousPage 2 of 2