Netlify deploy does not support node 14 or ecmascript 2020 syntax

Site ID: rhythm-plus
Build logs: https://app.netlify.com/sites/rhythm-plus/deploys/5f3ce92778f8dfac40b9da17

As shown in the logs, the node version is set to v12.18.0, that causes issue while parsing the webpack.config.js, syntax like nullish coalescing (??) throws an Unexpected token exception:

9:56:48 AM: $ npm run build
9:56:49 AM: > NODE_ENV=production webpack --mode production
9:56:49 AM: /opt/build/repo/webpack.config.js:7
9:56:49 AM: const version = packageJson.version ?? 0;
9:56:49 AM: ^
9:56:49 AM: SyntaxError: Unexpected token ‘?’
9:56:49 AM: at new Script (vm.js:88:7)

Is there any way to configure the node version or any other way to solve this? As there weren’t any problem when I build locally or on travis CI. Thank you!

hiya, you can absolutely configure the node version.

Give this a read through:

let us know if you need more help.