Open g8up opened 5 years ago
I used glob to refer the dll file, and got an error:
Error: Cannot find module '../static/js/*/.dll.js' Does require.resolve() api realy support glob ?
require.resolve()
MyProject ├───build │ └───webpack.prod.conf.js ├───static │ └───js │ └───library_xxx.dll.js └───package.json
new AddAssetHtmlPlugin({ filepath: require.resolve(`../static/js/**/*.dll.js`), }),
Might be better to do path.resolve(__dirname, '../static/js/**/*.dll.js'). If that works, wanna send a PR updating the docs?
path.resolve(__dirname, '../static/js/**/*.dll.js')
try this:
new AddAssetHtmlPlugin({ filepath: `../static/js/**/*.dll.js`, }),
I used glob to refer the dll file, and got an error: