-
-
Notifications
You must be signed in to change notification settings - Fork 284
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use ESBuild instead of Webpack #1672
Comments
I'm not opposed in theory, but my experience with js build systems is rooted in much pain and so I wonder how much effort it would be to make the change. |
Yeah, it's just an effort question to me. The current setup has worked for a while and it's the part of the codebase I'm least-comfortable with, so I'm change-averse. |
I might give it a try this weekend, one can know if it'll work under a couple of hours so if I face anything weird I'll report back |
Nice! Would be great if we could get a |
Interesting! But I think you still want |
oh certainly |
I went out and checked (with vite as opposed to raw esbuild) and after some inspection and looking after the code I have a few questions:
I can only think webpack was there to transpile back early fable code where electron didn't support esm, and perhaps even some ES201X features, this is no longer the case the recent node/electron versions support all of the features that fable transpile as far as I'm aware, we could ditch it entirely to be honest. The only reason I can think to have an extra build/bundling tool would be if extensions need to have bundled javascript files rather than transpiled and minified source code. I think we should be able to just run fable in watch mode in the back and then just launch the extension with the direct output of fable there would be some work to be done in regards imported members without extensions but I think over all it could be worth exploring thoughts? |
That's an interesting idea for sure. I don't think we do anything special - as long as we can emit source maps that should be all we need. The VSCode docs highly suggest bundling for a perf benefit, but realistically our extension isn't really that large at all. Perhaps shipping an unbundled version would be better for debugging? |
I would still bundle for production as the docs say, you don't know upfront what target (desktop/browser) you are dealing with so you want maximum coverage. |
Hey Sorry I forgot to report back here |
Hello, as webpack is no longer what the cool kids use, I'm wondering if you would be open to swapping it for esbuild?
The text was updated successfully, but these errors were encountered: