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

Glob pattern doesn't work #146

Open
g8up opened this issue Dec 30, 2018 · 2 comments
Open

Glob pattern doesn't work #146

g8up opened this issue Dec 30, 2018 · 2 comments

Comments

@g8up
Copy link

g8up commented Dec 30, 2018

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 ?

MyProject
├───build
│   └───webpack.prod.conf.js
├───static
│   └───js
│       └───library_xxx.dll.js
└───package.json
  • webpack.prod.conf.js
new AddAssetHtmlPlugin({
  filepath: require.resolve(`../static/js/**/*.dll.js`),
}),
@SimenB
Copy link
Owner

SimenB commented Dec 31, 2018

Might be better to do path.resolve(__dirname, '../static/js/**/*.dll.js'). If that works, wanna send a PR updating the docs?

@ssehacker
Copy link

ssehacker commented Sep 19, 2019

try this:

new AddAssetHtmlPlugin({
  filepath: `../static/js/**/*.dll.js`,
}),

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

No branches or pull requests

3 participants