Closed adventurini closed 1 year ago
Was facing the same issue but resolved when I updated my node version from v12.22.7 to v14.18.1
@adventurini could you mention the Node.js version you're using? You're using optional chaining which is only supported in Node.js v14+
The comment above also points to this 😄
Describe the bug Receiving an error after running
npm run build
fromnext-sitemap/dist/esm/cli.js:42
To Reproduce
package.json
:sitemap.config.js
---> have tried several renditions (export default config, etc.)tsconfig.json
Expected behavior Build the sitemap.