developit / developit/optimize-plugin

Cannot read property 'arguments' of undefined

Open
#12 3 comments 2 reactions 0 assignees View on GitHub
bug upstream
Dominant language
JavaScript
Stars
651
Forks
13
PR merge metrics
No merged PRs in 30d

Description

* webpack@5.10.0
* optimize-plugin@1.0.0
* node: v15.2.0

```bash
Build completed in 78.241s

Build completed in 0s

TypeError: /Users/weiran/repo/dian/honor/assets/~containers~a~count~cash-114e7fb5.js: Cannot read property 'arguments' of undefined
at NodePath._getKey (/Users/weiran/repo/dian/honor/node_modules/optimize-plugin/node_modules/@babel/traverse/lib/path/family.js:194:25)
at NodePath.get (/Users/weiran/repo/dian/honor/node_modules/optimize-plugin/node_modules/@babel/traverse/lib/path/family.js:186:17)
at NodePath._getPattern (/Users/weiran/repo/dian/honor/node_modules/optimize-plugin/node_modules/@babel/traverse/lib/path/family.js:226:21)
at NodePath.get (/Users/weiran/repo/dian/honor/node_modules/optimize-plugin/node_modules/@babel/traverse/lib/path/family.js:188:17)
at visitParam (/Users/weiran/repo/dian/honor/node_modules/babel-preset-modernize/dist/plugins/transform-destructuring/index.js:1:5836)
at PluginPass.VariableDeclarator (/Users/weiran/repo/dian/honor/node_modules/babel-preset-modernize/dist/plugins/transform-destructuring/index.js:1:7332)
at newFn (/Users/weiran/repo/dian/honor/node_modules/optimize-plugin/node_modules/@babel/traverse/lib/visitors.js:175:21)
at NodePath._call (/Users/weiran/repo/dian/honor/node_modules/optimize-plugin/node_modules/@babel/traverse/lib/path/context.js:55:20)
at NodePath.call (/Users/weiran/repo/dian/honor/node_modules/optimize-plugin/node_modules/@babel/traverse/lib/path/context.js:42:17)
at NodePath.visit (/Users/weiran/repo/dian/honor/node_modules/optimize-plugin/node_modules/@babel/traverse/lib/path/context.js:92:31)
error Command failed with exit code 1.
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.