Kocal / vue-web-extension

🛠️ A Vue CLI 3+ preset (previously a Vue CLI 2 boilerplate) for quickly starting a web extension with Vue, Babel, ESLint and more!
https://vue-web-extension.netlify.app/
MIT License
1.58k stars 167 forks source link

执行 “npm install -g @vue/cli npm install -g @vue/cli-init vue create --preset kocal/vue-web-extension my-extension” 提示Error resolving webpackConfig TypeError: Cannot read property 'ignore' of undefined .. ....new-tab-page\node_modules\vue-cli-plugin-browser-extension\index.js:129:20 #687

Open myFingerTip opened 1 year ago

myFingerTip commented 1 year ago

Describe the bug Error reported in initialization project

To Reproduce Steps to reproduce the behavior:

  1. npm install -g @vue/cli
  2. npm install -g @vue/cli-init
  3. vue create --preset kocal/vue-web-extension my-extension
  4. @vue/cli-plugin-eslint: Standard Lint on save
  5. vue-cli-plugin-browser-extension:Which browser extension components do you wish to generate? background, popup, options, content scripts, override, standalone, dev tools;Generate a new signing key (danger)? No 6.Preset options:? Install axios? Yes 7.Running completion hooks... Error resolving webpackConfig TypeError: Cannot read property 'ignore' of undefined at D:\chrome_plugins\c_tab\new-tab-page\node_modules\vue-cli-plugin-browser-extension\index.js:129:20

Expected behavior A clear and concise description of what you expected to happen.

Screenshots If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

jawt94 commented 1 year ago

having the same issue!

OakTre commented 1 year ago

same problem

taticohu commented 1 year ago

same problem

udaykiranchenna2 commented 1 year ago

Any solution?

bigyanghimire commented 1 year ago

what's the solution??

ryanscottmalmoe commented 1 year ago

The error is from the path to the ignore property being moved. Changing line 129 in vue-cli-plugin-browser-extension/index.js

args[0][0].ignore.push('browser-extension.html'); to --> args[0].patterns[0].globOptions.ignore.push('browser-extension.html');

Fixed it for me.