Skip to content

@vue/cli-service html-webpack-plugin [DEP_WEBPACK_COMPILATION_ASSETS] DeprecationWarning: Compilation.assets will be frozen in future, all modifications are deprecated. #6236

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

Closed
rubickecho opened this issue Jan 25, 2021 · 1 comment · Fixed by #6269
Labels
intend to implement The team has the intention to implement this feature at some point. Contribution is also welcome.

Comments

@rubickecho
Copy link

Version

5.0.0-alpha.3

Reproduction link

https://github.com/peakcool/vue-cli-service-html-webpack-plugin-demo

Environment info

Environment Info:

  System:
    OS: macOS 11.1
    CPU: (4) x64 Intel(R) Core(TM) i5-7360U CPU @ 2.30GHz
  Binaries:
    Node: 14.15.1 - ~/.nvm/versions/node/v14.15.1/bin/node
    Yarn: 1.22.10 - ~/.nvm/versions/node/v14.15.1/bin/yarn
    npm: 6.14.8 - ~/.nvm/versions/node/v14.15.1/bin/npm
  Browsers:
    Chrome: 88.0.4324.96
    Edge: 87.0.664.75
    Firefox: Not Found
    Safari: 14.0.2
  npmPackages:
    @vue/babel-helper-vue-jsx-merge-props:  1.2.1
    @vue/babel-helper-vue-transform-on:  1.0.2
    @vue/babel-plugin-jsx:  1.0.2
    @vue/babel-plugin-transform-vue-jsx:  1.2.1
    @vue/babel-preset-app:  5.0.0-alpha.3
    @vue/babel-preset-jsx:  1.2.4
    @vue/babel-sugar-composition-api-inject-h:  1.2.1
    @vue/babel-sugar-composition-api-render-instance:  1.2.4
    @vue/babel-sugar-functional-vue:  1.2.2
    @vue/babel-sugar-inject-h:  1.2.2
    @vue/babel-sugar-v-model:  1.2.3
    @vue/babel-sugar-v-on:  1.2.3
    @vue/cli-overlay:  5.0.0-alpha.3
    @vue/cli-plugin-babel: ~5.0.0 => 5.0.0-alpha.3
    @vue/cli-plugin-eslint: ~5.0.0 => 5.0.0-alpha.3
    @vue/cli-plugin-router:  5.0.0-alpha.3
    @vue/cli-plugin-vuex:  5.0.0-alpha.3
    @vue/cli-service: ~5.0.0 => 5.0.0-alpha.3
    @vue/cli-shared-utils:  5.0.0-alpha.3
    @vue/component-compiler-utils:  3.2.0
    @vue/preload-webpack-plugin:  1.1.2
    @vue/web-component-wrapper:  1.2.0
    eslint-plugin-vue: ^7.2.0 => 7.5.0
    vue: ^2.6.11 => 2.6.12
    vue-eslint-parser:  7.4.1
    vue-hot-reload-api:  2.3.4
    vue-loader:  16.1.2 (15.9.6)
    vue-style-loader:  4.1.2
    vue-template-compiler: ^2.6.11 => 2.6.12
    vue-template-es2015-compiler:  1.9.1
  npmGlobalPackages:
    @vue/cli: Not Found

Steps to reproduce

> npm run serve

What is expected?

no warning

What is actually happening?

Terminal console throws

 INFO  Starting development server...
95% emitting emit(node:18417) [DEP_WEBPACK_COMPILATION_ASSETS] DeprecationWarning: Compilation.assets will be frozen in future, all modifications are deprecated.
BREAKING CHANGE: No more changes should happen to Compilation.assets after sealing the Compilation.
	Do changes to assets earlier, e. g. in Compilation.hooks.processAssets.
	Make sure to select an appropriate stage from Compilation.PROCESS_ASSETS_STAGE_*.
(Use `node --trace-deprecation ...` to show where the warning was created)
99% done plugins FriendlyErrorsWebpackPlugin

 DONE  Compiled successfully in 2875ms

Inquire some information, can find the solution here:jantimon/html-webpack-plugin#1523

I tried to update html-webpack-plugin version 4.5.1 => 5.0.0-beta.6, it work

So consider using html-webpack-plugin 5.0 by default for @vue/cli-service

@haoqunjiang haoqunjiang added the intend to implement The team has the intention to implement this feature at some point. Contribution is also welcome. label Jan 25, 2021
@awill1988
Copy link
Contributor

@sodatea, please see #6277 -- I believe lib/HtmlPwaPlugin.js still produces the warning when the manifest.json is generated and emitted.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
intend to implement The team has the intention to implement this feature at some point. Contribution is also welcome.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants