Skip to content

Alphacodeclub/EmployeeDataGraphQL

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 

Repository files navigation

EmployeeDataGraphQL

adding employeeData using graphQL deleting employeeData using graphQL editing employeeData using graphQL

RUN

Make Seperate data.json file as for adding EmployeeData in json format

  1. Install Dependencies - npm install ( axios": "^0.16.2","express": "^4.15.3","express-graphql": "^0.6.7","graphql": "^0.10.5","json-server": "^0.11.2", "nodemon": "^1.11.0")
  2. npm run dev:server
  3. npm run json:server
  4. Browse localhost:4000/graphql

Queries

**QueryFormat** query{ employees{ id name age developerType } }

//Mutation Format addEmployee mutation{ addEmployee(name:"add employeeName", age:add EmployeeAge, email:"[email protected]", developerType:"AddDeveloperType"){ id name age developerType email } }

//editEmployee mutation{ editEmployee(id:1, age:add EmployeeAge, email:"[email protected]", developerType:"AddDeveloperType"){ id name age developerType email } }

//deleteEmployee mutation{ deleteEmployee(id:1){ id name age developerType email } } `

About

EmployeeData Application using GraphQL

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%