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

Webpack 5 support? #126

Open
dhruvkb opened this issue Jun 17, 2021 · 5 comments
Open

Webpack 5 support? #126

dhruvkb opened this issue Jun 17, 2021 · 5 comments

Comments

@dhruvkb
Copy link

dhruvkb commented Jun 17, 2021

Does the plugin support Webpack 5 which will be the default in Vue CLI 5?

Adding the plugin in a new Vue CLI 5 project (with TypeScript) generates the following error:

ERROR  TypeError: Cannot read property 'ignore' of undefined
TypeError: Cannot read property 'ignore' of undefined
    at /Users/x/test_app/node_modules/vue-cli-plugin-browser-extension/index.js:129:20
    at Object.tap (/Users/x/test_app/node_modules/webpack-chain/src/Plugin.js:30:24)
    at /Users/x/test_app/node_modules/vue-cli-plugin-browser-extension/index.js:128:36
    at /Users/x/test_app/node_modules/@vue/cli-service/lib/Service.js:266:40
    at Array.forEach (<anonymous>)
    at Service.resolveChainableWebpackConfig (/Users/x/test_app/node_modules/@vue/cli-service/lib/Service.js:266:26)
    at PluginAPI.resolveChainableWebpackConfig (/Users/x/test_app/node_modules/@vue/cli-service/lib/PluginAPI.js:145:25)
    at module.exports (/Users/x/test_app/node_modules/@vue/cli-service/lib/commands/build/resolveAppConfig.js:9:22)
    at build (/Users/x/test_app/node_modules/@vue/cli-service/lib/commands/build/index.js:147:50)
    at /Users/x/test_app/node_modules/@vue/cli-service/lib/commands/build/index.js:69:13
    at Service.run (/Users/x/test_app/node_modules/@vue/cli-service/lib/Service.js:260:12)
    at processTicksAndRejections (internal/process/task_queues.js:93:5)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! test_app@1.0.0 serve: `vue-cli-service build --mode development --watch`
npm ERR! Exit status 1
npm ERR! 

@Rhilip
Copy link

Rhilip commented Nov 9, 2021

I also want this feature, Vue CLI 5 is in RC status now, and It is time to update this repo.
In my test, this TypeError is because of copy-webpack-plugin, as they change the args structure.
However, not only this dependency is old, the webpack-extension-reloader dependency is also not support for webpack, and should change it to https://github.com/SimplifyJobs/webpack-ext-reloader.
More the dependency webextension-polyfill is also old to use , and can be update to 0.8.0


I found a fork https://github.com/mikelxk/vue-cli-plugin-browser-extension which support webpack 5 !!!! (see below comment )

@Rhilip
Copy link

Rhilip commented Dec 31, 2021

I fork this project and did some work to make it support webpack 5, You can Visit pt-plugins@7e19baf to see more detail,
Since mikelxk/vue-cli-plugin-browser-extension lost a dependency and a very import work in new vue-cli 5.x is not done in this project.

Change package.json to "vue-cli-plugin-browser-extension": "Rhilip/vue-cli-plugin-browser-extension",, My full merge commit is like pt-plugins/PT-Plugin-Plus@5b94715


Update at 2022.12.17:

  1. Repo: https://github.com/pt-plugins/vue-cli-plugin-browser-extension , Please See full README.md
  2. I publish my fork to npm, so everyone can replace with new "vue-cli-plugin-browser-extension": "npm:@rhilip/vue-cli-plugin-browser-extension@^0.27.0",
  3. my fork is not support MV3, though issue add support for Manifest v3 #107 and pull Add support for manifest-v3 Content Security Policy #131 provide a patch for this vue-cli extension. There still some deep dependencies not support MV3, like SimplifyJobs/webpack-ext-reloader (see MV3 Support? SimplifyJobs/webpack-ext-reloader#28 )

@sherifmayika
Copy link

Manifest v3 support is there already : SimplifyJobs/webpack-ext-reloader#28

@Rhilip
Copy link

Rhilip commented Dec 15, 2022

Manifest v3 support is there already : SimplifyJobs/webpack-ext-reloader#28

I see this issue and connected pr, however no merge and release.
Since SimplifyJobs/webpack-ext-reloader lack maintenance, I may want to remove this deps or replace it to another.

@sherifmayika
Copy link

sherifmayika commented Sep 29, 2023

https://github.com/SimplifyJobs/webpack-ext-reloader is now upgraded to MV3
Please release a compatible version

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