RFC: removing Babel #738
Replies: 2 comments 5 replies
-
anyone? I'd create a PR but only if there's a chance it could get merged :D |
Beta Was this translation helpful? Give feedback.
-
Hey @chris-schra — I think we would be very open to modifying our Webpack config to improve its performance, although removing Babel will have a lot of consequences and is not going to be a straightforward thing to do. Our Payload config supports TypeScript, JSX, etc and should be able to be imported into any Node environment. This means that it needs to go through Babel or similar to ensure it can be parsed, even in vanilla JS / node environments. We have a fair amount of things in-flight for our upcoming 1.0 release at the moment, but I am happy to help here in a few months once we have our current tasks completed. PS - now that the three co-founders are all on Payload full-time, our velocity has increased a TON. :) |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Dear All,
I experimented a bit because on my corporate-bloated notebook payload takes a while to start.
I've already migrated to esbuild-loader which drops build time 3x but there's one last thing: in load and index there's a "hard" require of babel/register.
My suggestion - if anyone is interested - is, to add a config flag like experimentalEsbuild?:boolean that would patch the webpack config and skip the requires of babel (drops time "Starting Payload..." to "Connected to Mongo Server successfully..."
With babel (only talking about the startup time with local:false):
No babel:
For reference, this is my working ESBuild config:
Beta Was this translation helpful? Give feedback.
All reactions