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

Is next-pwa is deprecated? #241

Open
satyamskillz opened this issue Jul 21, 2021 · 3 comments
Open

Is next-pwa is deprecated? #241

satyamskillz opened this issue Jul 21, 2021 · 3 comments
Labels
bug Something isn't working question Further information is requested

Comments

@satyamskillz
Copy link

Summary

Recently, I noticed that NextJS 11 is shifted to Webpack 5 and JEST is renamed to JOI. when I am running my application production or development is don't see next-PWA generating any files. and I got these warnings during installation.

warning next > native-url > querystring@0.2.1: The querystring API is considered Legacy. new code should use the URLSearchParams API instead.
warning next > node-libs-browser > url > querystring@0.2.0: The querystring API is considered Legacy. new code should use the URLSearchParams API instead.
warning next-pwa > workbox-webpack-plugin > workbox-build > rollup-plugin-babel@4.4.0: This package has been deprecated and is no longer maintained. Please use @rollup/plugin-babel.
warning next-pwa > workbox-webpack-plugin > workbox-build > @hapi/joi@15.1.1: Switch to 'npm install joi'
warning next-pwa > workbox-webpack-plugin > workbox-build > @hapi/joi > @hapi/hoek@8.5.1: This version has been deprecated and is no longer supported or maintained        
warning next-pwa > workbox-webpack-plugin > workbox-build > @hapi/joi > @hapi/topo@3.1.6: This version has been deprecated and is no longer supported or maintained        
warning next-pwa > workbox-webpack-plugin > workbox-build > @hapi/joi > @hapi/topo > @hapi/hoek@8.5.1: This version has been deprecated and is no longer supported or maintained
warning next-pwa > workbox-webpack-plugin > workbox-build > @hapi/joi > @hapi/address@2.1.4: Moved to 'npm install @sideway/address'
warning next-pwa > workbox-webpack-plugin > workbox-build > @hapi/joi > @hapi/bourne@1.3.2: This version has been deprecated and is no longer supported or maintained      
warning next-pwa > workbox-webpack-plugin > workbox-build > strip-comments > babel-plugin-transform-object-rest-spread > babel-runtime > core-js@2.6.12: core-js@<3.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Please, upgrade your dependencies to the actual version of core-js.
[2/4] Fetching packages...
info fsevents@2.3.2: The platform "win32" is incompatible with this module.
info "fsevents@2.3.2" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
warning " > next-pwa@3.1.5" has unmet peer dependency "webpack@>=4.0.0".
warning "next-pwa > clean-webpack-plugin@3.0.0" has unmet peer dependency "webpack@*".
warning "next-pwa > workbox-webpack-plugin@5.1.4" has unmet peer dependency "webpack@^4.0.0".

When I tried to run the old Nextjs example from here link I got these warnings. what is happing?

(node:11604) [DEP_WEBPACK_SINGLE_ENTRY_PLUGIN] DeprecationWarning: SingleEntryPlugin was renamed to EntryPlugin
(Use `node --trace-deprecation ...` to show where the warning was created)
> [PWA] Compile client (static)
> [PWA] Build in develop mode, cache and precache are mostly disabled. This means offline support is disabled, but you can continue developing other functions in service worker.
> [PWA] Auto register service worker with: D:\NEXT-JS\progressive-web-app\node_modules\next-pwa\register.js
> [PWA] Service worker: D:\NEXT-JS\progressive-web-app\public\sw.js
> [PWA]   url: /sw.js
> [PWA]   scope: /
> [PWA] Compile server
@rollup/plugin-replace: 'preventAssignment' currently defaults to false. It is recommended to set this option to `true`, as the next major version will default this option to `true`.
(node:11604) [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_*.

Versions

  • next-pwa: ^5.2.24
  • next: ^11.0.1
@satyamskillz satyamskillz added the bug Something isn't working label Jul 21, 2021
@shadowwalker
Copy link
Owner

  1. What make you think next-pwa is deprecated?
  2. What make you think "JEST is renamed to JOI"?
  3. I don't maintain the example inside next.js repository unfortunately, does the examples in this repository not good enough for you?

@shadowwalker shadowwalker added the question Further information is requested label Jul 25, 2021
@satyamskillz
Copy link
Author

  1. What this line means (node:11604) [DEP_WEBPACK_COMPILATION_ASSETS] DeprecationWarning: Compilation.assets will be frozen in future, all modifications are deprecated?
  2. warning next-pwa > workbox-webpack-plugin > workbox-build > @hapi/joi@15.1.1: Switch to 'npm install joi'.
  3. Yes, I understand that most of the next.js examples are outdated, after this recent version update most of the examples are giving deprecation warning. my application is totally dependent on pwa, that's why I don't want to use any packages such as next-pwa and next-sitemap which might cause problems in future.

@renomureza
Copy link

renomureza commented Aug 1, 2021

I have installed this plugin and when this plugin is uninstalled, Vercel returns 500 internal server error.

This seems to be messing with package-lock.json (babel/core), hope this can be a hint of a fix.

I was stuck in the same problem, finally solved. Remove target: 'serverless' in next.config.js. Ref: vercel/next.js#10633

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working question Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants