3 ms·
Modern React uses JSX which is then transformed at build time into function calls. You can write those function calls yourself, but it would be a tremendous PI
by pier25 6y ago
Modern React uses JSX which is then transformed at build time into function calls.
You can write those function calls yourself, but it would be a tremendous PITA.
- lhnz 6y agoIn this case, you could use `htm`: https://github.com/developit/htm#usage https://github.com/developit/htm#usage
- pier25 6y agoYeah totally. Or even use Preact by the same author which is smaller and faster than React.
- jonquest 6y agoThat's cool- but unless you're targeting greenfield browsers only you aren't going to use the syntax in that documentation without a build step or using the babel transpiler directly in the browser which, while cool from a POC standpoint, isn't a good solution. At that point you might as well just add build tools and use JSX or whatever the framework you're trying to use intended or otherwise is well documented.