Show HN: JSX in Browser with Sucrase (altbdoor.github.io)
Been working on a number of React projects, and was intrigued a little by JSX. I wanted to make running JSX in browser easier, so I tried my hand at using a service worker, to transpile JSX on the fly.
I started with @babel/standalone, but the library was heavy enough to notice a delay on the browser. I found out about sucrase a little later, and tried building it for the browser, and voila!
Didn't really thoroughly test if everything JSX is supported, but it seems fine for small learning or prototyping.
2 comments
[ 1554 ms ] story [ 902 ms ] threadThe demo page is only to show how we can transpile JSX in browsers.