covidpass-org / covidpass

Web app for adding EU Digital COVID Certificates to your wallet apps
https://covidpass.marvinsextro.de
MIT License
1.18k stars 62 forks source link

Trying to run yarn dev results in SyntaxError #80

Closed TheGlobalist closed 3 years ago

TheGlobalist commented 3 years ago

Hi! I wanted to run the Front-End application on my computer. For doing that, I've simply cloned this repository, then executed yarn install and yarn dev but got, instead...

`(base) MacBook-Pro-193:covidpass gimmi$ yarn install yarn install v1.22.11 warning package-lock.json found. Your project contains lock files generated by tools other than Yarn. It is advised not to mix package managers in order to avoid resolution inconsistencies caused by unsynchronized lock files. To clear this warning, remove package-lock.json. [1/4] 🔍 Resolving packages... success Already up-to-date. ✨ Done in 0.28s. (base) MacBook-Pro-193:covidpass gimmi$ npm run dev

covidpass@0.1.0 dev next dev

ready - started server on 0.0.0.0:3000, url: http://localhost:3000 info - Using webpack 5. Reason: Enabled by default https://nextjs.org/docs/messages/webpack5 event - compiled successfully event - build page: /next/dist/pages/_error wait - compiling... event - compiled successfully event - build page: / wait - compiling... event - compiled successfully /Users/gimmi/Desktop/prova/covidpass/node_modules/pdfjs-dist/build/pdf.js:2205 annotationStorage: annotationStorage?.serializable || null ^

SyntaxError: Unexpected token '.' at wrapSafe (internal/modules/cjs/loader.js:1072:16) at Module._compile (internal/modules/cjs/loader.js:1122:27) at Object.Module._extensions..js (internal/modules/cjs/loader.js:1178:10) at Module.load (internal/modules/cjs/loader.js:1002:32) at Function.Module._load (internal/modules/cjs/loader.js:901:14) at Module.require (internal/modules/cjs/loader.js:1044:19) at require (internal/modules/cjs/helpers.js:77:18) at Object.pdfjs-dist (/Users/gimmi/Desktop/prova/covidpass/.next/server/pages/index.js:623:18) at __webpack_require__ (/Users/gimmi/Desktop/prova/covidpass/.next/server/webpack-runtime.js:33:42) at eval (webpack-internal:///./src/process.ts:8:68) ^C(base) MacBook-Pro-193:covidpass gimmi$ `

My env is a MBP M1 with Mac OS Big Sur and npm 7.x. Does anybody know how to solve this?

marvinsxtr commented 3 years ago

I got a similar error when I had an older node.js version. 14.x should be fine.

marvinsxtr commented 3 years ago

Does it work with a newer node.js version?

marvinsxtr commented 3 years ago

Closing due to inactivity.