Execute the following steps from your Cloud9 terminal.
cd ~/environment
mkdir frontend
touch frontend/package.json
nvm install lts/erbium
nvm use lts/erbium
Then paste the following dependency declaration into frontend/package.json
,
remembering to save the file afterwards:
{
"name": "frontend",
"version": "0.1.0",
"private": true,
"dependencies": {
"@apollo/client": "^3.1.3",
"@apollo/react-hooks": "^3.1.5",
"@aws-amplify/auth": "^3.3.4",
"@aws-amplify/core": "^3.4.5",
"@testing-library/jest-dom": "^5.11.6",
"@testing-library/react": "^11.2.0",
"@testing-library/user-event": "^12.2.2",
"apollo-client": "^2.6.10",
"apollo-link": "^1.2.14",
"apollo-link-ws": "^1.0.20",
"aws-appsync-auth-link": "^2.0.2",
"aws-appsync-subscription-link": "^2.2.0",
"graphql": "^15.3.0",
"graphql-tag": "^2.11.0",
"moment": "^2.27.0",
"react": "^16.8.0",
"react-apollo": "^3.1.5",
"react-dom": "^16.8.0",
"react-scripts": "3.4.4",
"web-vitals": "^0.2.4"
},
"scripts": {
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test",
"eject": "react-scripts eject"
},
"eslintConfig": {
"extends": [
"react-app",
"react-app/jest"
]
},
"browserslist": {
"production": [
">0.2%",
"not dead",
"not op_mini all"
],
"development": [
"last 1 chrome version",
"last 1 firefox version",
"last 1 safari version"
]
}
}
Enter the frontend
folder and install some additional dependencies.
nvm use lts/erbium
cd ~/environment/frontend
npm install
This will take a few minutes and eventually return with a message like this.
...
added 2000 packages from 875 contributors and audited 2007 packages in 40.865s
77 packages are looking for funding
run `npm fund` for details
found 0 vulnerabilities