You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was too eager to test my react-template-render library in koa-skeleton and thus replaced my Pug templates with .jsx templates. But now I need Babel to compile .jsx into .js.
I was too eager to test my
react-template-render
library in koa-skeleton and thus replaced my Pug templates with .jsx templates. But now I need Babel to compile .jsx into .js.The easiest solution was to use babel-register:
koa-skeleton/src/index.js
Lines 4 to 7 in 30ccf95
But it brings a thick runtime dependency, probably slows down large project boot, and probably degrades the quality of stack traces.
Better would be to compile .jsx to .js physically with a watch script.
It's kind of lame to have a build step at all on a server, but so far .jsx templates have been worth it. Prob on par with what I had with Pug.
The text was updated successfully, but these errors were encountered: