typescript type generations from graphql

This commit is contained in:
Xetera
2019-07-27 00:14:02 -07:00
parent 7f7e713f9f
commit fd43a02f8d
5 changed files with 3926 additions and 20 deletions
+1
View File
@@ -0,0 +1 @@
src/generated/* linguist-vendored
+8
View File
@@ -0,0 +1,8 @@
overwrite: true
schema: "http://localhost:8000/___graphql"
documents: "src/**/*.graphql"
generates:
src/generated/graphql.ts:
plugins:
- "typescript"
- "typescript-operations"
+1214 -18
View File
File diff suppressed because it is too large Load Diff
+8 -2
View File
@@ -11,6 +11,7 @@
"gatsby": "^2.13.39", "gatsby": "^2.13.39",
"gatsby-image": "^2.2.6", "gatsby-image": "^2.2.6",
"gatsby-plugin-manifest": "^2.2.4", "gatsby-plugin-manifest": "^2.2.4",
"gatsby-plugin-mdx": "^1.0.17",
"gatsby-plugin-offline": "^2.2.4", "gatsby-plugin-offline": "^2.2.4",
"gatsby-plugin-react-helmet": "^3.1.2", "gatsby-plugin-react-helmet": "^3.1.2",
"gatsby-plugin-sass": "^2.1.3", "gatsby-plugin-sass": "^2.1.3",
@@ -32,10 +33,14 @@
"styled-components": "^4.3.2" "styled-components": "^4.3.2"
}, },
"devDependencies": { "devDependencies": {
"@graphql-codegen/cli": "^1.4.0",
"@types/react": "^16.8.23", "@types/react": "^16.8.23",
"@types/react-dom": "^16.8.5", "@types/react-dom": "^16.8.5",
"@types/react-helmet": "^5.0.8", "@types/react-helmet": "^5.0.8",
"prettier": "^1.18.2" "prettier": "^1.18.2",
"@graphql-codegen/typescript": "1.4.0",
"@graphql-codegen/typescript-operations": "1.4.0",
"@graphql-codegen/typescript-react-apollo": "1.4.0"
}, },
"keywords": [ "keywords": [
"gatsby" "gatsby"
@@ -47,7 +52,8 @@
"format": "prettier --write src/**/*.{js,jsx}", "format": "prettier --write src/**/*.{js,jsx}",
"start": "npm run develop", "start": "npm run develop",
"serve": "gatsby serve", "serve": "gatsby serve",
"test": "echo \"Write tests! -> https://gatsby.dev/unit-testing\"" "test": "echo \"Write tests! -> https://gatsby.dev/unit-testing\"",
"codegen": "graphql-codegen --config codegen.yml"
}, },
"repository": { "repository": {
"type": "git", "type": "git",
+2695
View File
File diff suppressed because it is too large Load Diff