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

SyntaxError in webpack.config.js #15

Closed
PululuK opened this issue Mar 30, 2021 · 5 comments
Closed

SyntaxError in webpack.config.js #15

PululuK opened this issue Mar 30, 2021 · 5 comments

Comments

@PululuK
Copy link
Contributor

PululuK commented Mar 30, 2021

During the installation process (step 6), when you try to run npm run dev
You have :

/themes/starter/_dev/webpack.config.js:20
  purge: options?.purge ? options.purge : false,
                 ^

SyntaxError: Unexpected token '.'
    at wrapSafe (internal/modules/cjs/loader.js:915:16)
    at Module._compile (internal/modules/cjs/loader.js:963:27)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
    at Module.load (internal/modules/cjs/loader.js:863:32)
    at Function.Module._load (internal/modules/cjs/loader.js:708:14)
    at Module.require (internal/modules/cjs/loader.js:887:19)
    at require (internal/modules/cjs/helpers.js:74:18)

Env infos

  • Node : v12.20.1
  • Branch : develop
  • Prestashop : 1.7.7.2
@Oksydan
Copy link
Owner

Oksydan commented Mar 30, 2021

Thanks for your feedback.
What is your node version?

@PululuK
Copy link
Contributor Author

PululuK commented Mar 30, 2021

Hi @Oksydan
I just add my env infos in issue description 😀
Thanks

@Oksydan
Copy link
Owner

Oksydan commented Mar 30, 2021

@PululuK
soo node.js is the reason, optional chanings works with node >= 14.0.0 https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Optional_chaining.
I wrote in readme.md that starter required node >= 15.0.0.
We can lower the requirements with this PR but I will have to test it.
Give me one day and I will give you my response. It was there for a reason.

@PululuK
Copy link
Contributor Author

PululuK commented Mar 30, 2021

actually I think the requirement for the node is quite high 😟
Yep ... take your time to test 😉

@Oksydan
Copy link
Owner

Oksydan commented Mar 31, 2021

@PululuK
I am back with the news. I tested with node down to version 9. It isn't working with node 9 but with 10 it is ok. So I am going to merge your change and update docs to lower node version requirements to 10. Thank you.

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

2 participants