Next-pwa: Custom-ts-worker not work well on [email protected]

Created on 3 Apr 2021  路  3Comments  路  Source: shadowwalker/next-pwa

Summary

The latest version does not work properly in custom-ts-worker.

How To Reproduce

1.Download project from examples/custom-ts-worker
2.next dev

Expected Behaviors

Should compile no errors

Screenshots

custom-ts-worker yarn dev
yarn run v1.22.5
$ next
ready - started server on 0.0.0.0:3000, url: http://localhost:3000
/Users/zack/Downloads/next-pwa-master/examples/custom-ts-worker/node_modules/next-pwa/index.js:24
    let basePath = options.config.basePath ?? '/'
                                            ^

SyntaxError: Unexpected token '?'
    at wrapSafe (internal/modules/cjs/loader.js:1053:16)
    at Module._compile (internal/modules/cjs/loader.js:1101:27)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1157:10)
    at Module.load (internal/modules/cjs/loader.js:985:32)
    at Function.Module._load (internal/modules/cjs/loader.js:878:14)
    at Module.require (internal/modules/cjs/loader.js:1025:19)
    at require (internal/modules/cjs/helpers.js:72:18)
    at Object.<anonymous> (/Users/zack/Downloads/next-pwa-master/examples/custom-ts-worker/next.config.js:1:17)
    at Module._compile (internal/modules/cjs/loader.js:1137:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1157:10)
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

Additional Context

Add any other context about the problem here.

bug done

Most helpful comment

I finally got something working, please try next-pwa 5.1.3

All 3 comments

Please try 5.1.2

I finally got something working, please try next-pwa 5.1.3

It麓s working again, thank you man

Was this page helpful?
0 / 5 - 0 ratings