vue-web-extension icon indicating copy to clipboard operation
vue-web-extension copied to clipboard

执行 “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

Open myFingerTip opened this issue 1 year ago • 6 comments

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):

  • vue-web-extension version: ...
  • OS: Windows 10 企业版 22H2
  • Node.js version: v14.20.0
  • @vue/cli 5.0.8
  • npm 6.14.17 Additional context Add any other context about the problem here.

myFingerTip avatar Apr 03 '23 02:04 myFingerTip

having the same issue!

jawt94 avatar Apr 19 '23 14:04 jawt94

same problem

OakTre avatar Apr 21 '23 07:04 OakTre

same problem

taticohu avatar Apr 29 '23 04:04 taticohu

Any solution?

udaykiranchenna2 avatar Apr 29 '23 13:04 udaykiranchenna2

what's the solution??

bigyanghimire avatar May 01 '23 14:05 bigyanghimire

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.

ryanscottmalmoe avatar May 09 '23 18:05 ryanscottmalmoe