43 lines
881 B
Markdown
43 lines
881 B
Markdown
Installed the node.js using npm init. It walked through the package.json settings.
|
|
|
|
Installed apollo server and graphql npm install apollo-server@^2 graphql@^14.6.0
|
|
|
|
Can Run the project using node src/index.js
|
|
|
|
Installed typescript to the project npm install typescript --save-dev
|
|
Installed typescripts error runtime npm install ts-node typescript --save-dev
|
|
|
|
Running typescript compiler npx tsc
|
|
|
|
|
|
Restart server on save npm install -g nodemon
|
|
Run nodemon src/index.js instead of node src/index.js
|
|
|
|
INSTALL PRISMA
|
|
npm install prisma --save-dev
|
|
npm install @prisma/client
|
|
|
|
INSTALL WEBTOKENS JTK
|
|
npm install jsonwebtoken bcryptjs
|
|
|
|
Initialise prisma npx prisma init
|
|
|
|
|
|
Run the prisma migrate to update the database connections
|
|
npx prisma migrate dev
|
|
|
|
Generate prisma client
|
|
npx prisma generate
|
|
|
|
MIGRATE
|
|
npx prisma migrate dev
|
|
|
|
|
|
|
|
query {
|
|
link {
|
|
id
|
|
url
|
|
description
|
|
}
|
|
} |