执行:npm run build
The error is as follows:
Build packaging error: TypeError: Cannot read property 'get' of undefined
After looking at the content below the error report, we can see that the version of webpack is different.
It is because the version of webpack@5 is too high and the packaging fails to report an error. Just lower the version of webpack.
npm i --save webpack@4.46.0
It's fine to repack