-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Create ES6 build without inlined helpers for async-await, iterators, rest-spread etc #1898
Comments
Can you provide PR to help solve this problem? |
I've tried to investigate this but am stuck at running the project locally. Here's what I see in console after running
Tried running @crazylxr Can you help with overcoming this obstacle? |
@SpadarShut The problem may be the version of pnpm, please try with the |
@miracles1919 With pnpm 7.1.9 I get another error:
|
You could try switching to v16, or set Reference webpack/webpack#14532 |
Did you solve your problem? @SpadarShut |
I found how to fix the problem. Howewer, I have some questions:
|
@SpadarShut I've optimized the build, and I think defaults browserslist is ok, you can configure |
Have you considered changing |
Yeah, I have changed to es6 |
Esnext should be better here because this way TS compiler will do minimal changes and babel will do all the needed transforms according to browserslist config. |
OK |
I tried Webpack 4 doesn't supoort So when we upgrade webpack5, we may be able to use |
Currently every hook's code contains transpiled helpers like
__awaiter
,__generator
,__assign
,__rest
,__read
and others, which can amout to more code than hook itself.It would be great to not include them by default or have another build target as browser support for async-await, iterators, rest-spread etc in browsers which support es6 imports is very good nowadays.
The text was updated successfully, but these errors were encountered: