How to fix UglifyJS error `Unexpected token: punc ())`
[issue link]Often with third-party packages I got such errors
ERROR in pages/menuaim.2a58f05d2d2352aae6c1.js from UglifyJs
Unexpected token: punc ()) [./node_modules/menu-aim/src/index.js:1,0][pages/menuaim.2a58f05d2d2352aae6c1.js:173,2]
Error: Webpack build exited with errors
Is there’s a way to fix it? I can’t find the answer. May be I need some webpack settings? Because packages itself are working fine.