Skip to content
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

Uppy 2.4.0: Webpack fails to compile due to error: "Module parse failed: Identifier directly after number" #3421

Closed
thoiberg opened this issue Jan 11, 2022 · 0 comments · Fixed by #3422
Labels

Comments

@thoiberg
Copy link

When using Uppy 2.4.0, webpack fails to compile with the following error:

ERROR in ./node_modules/@uppy/transloadit/lib/index.js 427:21
Module parse failed: Identifier directly after number (427:21)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
|       getAssemblyOptions: defaultGetAssemblyOptions,
|       limit: 20,
>       retryDelays: [7_000, 10_000, 15_000, 20_000]
|     };
|     this.opts = { ...defaultOptions,
ℹ 「wdm」: Failed to compile.

This looks to be because of the JS numeric separators, when replacing

retryDelays: [7_000, 10_000, 15_000, 20_000],

with:

retryDelays: [7000, 10000, 15000, 20000]

it compiles properly

Environment

Node: 14.16.1
Wepack: 4.44.1 (through Webpacker 5.2.1
Mac OSX: 11.6.2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant