-
Notifications
You must be signed in to change notification settings - Fork 1
Node work
Franknaw edited this page Aug 15, 2021
·
6 revisions
- When running
node index.js
, received the following errors
npm update
npm WARN eslint-config-airbnb@18.2.1 requires a peer of eslint-plugin-import@^2.22.1 but none is installed. You must install peer dependencies yourself.
npm WARN eslint-config-airbnb@18.2.1 requires a peer of eslint-plugin-jsx-a11y@^6.4.1 but none is installed. You must install peer dependencies yourself.
npm WARN eslint-config-airbnb@18.2.1 requires a peer of eslint-plugin-react@^7.21.5 but none is installed. You must install peer dependencies yourself.
npm WARN eslint-config-airbnb@18.2.1 requires a peer of eslint-plugin-react-hooks@^4 || ^3 || ^2.3.0 || ^1.7.0 but none is installed. You must install peer dependencies yourself.
npm WARN eslint-config-airbnb-base@14.2.1 requires a peer of eslint-plugin-import@^2.22.1 but none is installed. You must install peer dependencies yourself.
npm WARN crms-parsers-terraform@1.0.0 No description
-
Install eslint
-
npm install eslint-config-airbnb@18.2.1
-
Now, when running
node index.js
received these errors
node index.js
Targets found: 1
/home/tnaw/dhs/dev/crms-parsers-terraform/src/utils/get-target-setting-values.js:7
)).flat()
^
TypeError: [].concat(...).filter(...).map(...).flat is not a function
at _.strings.unique.concat.filter.map.target (/home/tnaw/dhs/dev/crms-parsers-terraform/src/utils/get-target-setting-values.js:7:8)
at Array.map (<anonymous>)
at Object.getTargetSettingValues (/home/tnaw/dhs/dev/crms-parsers-terraform/src/utils/get-target-setting-values.js:4:73)
at targets.forEach.target (/home/tnaw/dhs/dev/crms-parsers-terraform/src/parsers/aws/vpc/static-subnet/index.js:21:28)
at Array.forEach (<anonymous>)
at Object.transform (/home/tnaw/dhs/dev/crms-parsers-terraform/src/parsers/aws/vpc/static-subnet/index.js:19:11)
at Object.<anonymous> (/home/tnaw/dhs/dev/crms-parsers-terraform/index.js:5:30)
at Module._compile (internal/modules/cjs/loader.js:778:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
at Module.load (internal/modules/cjs/loader.js:653:32)
-
Determined that I needed to update my node version to v12.x.
-
node --version v10.24.0
-
Needed to update node.
-
sudo dnf module list nodejs
CentOS Linux 8 - AppStream
Name Stream Profiles Summary
nodejs 10 [d][e] common [d], development, minimal, s2i Javascript runtime
nodejs 12 common [d], development, minimal, s2i Javascript runtime
nodejs 14 common [d], development, minimal, s2i Javascript runtime
Extra Packages for Enterprise Linux Modular 8 - x86_64
Name Stream Profiles Summary
nodejs 13 default, development, minimal Javascript runtime
Hint: [d]efault, [e]nabled, [x]disabled, [i]nstalled
sudo dnf module reset nodejs:10
sudo dnf module enable nodejs:12
sudo dnf install nodejs
node --version v12.22.3
npm --version 6.14.13