{"library":"gatsby-plugin-graphql-codegen","type":"library","category":null,"description":"A Gatsby plugin that automates TypeScript type generation for GraphQL queries using graphql-code-generator. Version 3.1.1 is the latest stable; it supports Gatsby >=3.0.0 and requires GraphQL ^15.0.0 and TypeScript as peer dependencies. Key differentiators: integrates seamlessly with Gatsby's build pipeline, auto-discovers query files, and supports additional schemas for client-side queries. Released under the MIT license with no known security incidents.","language":"javascript","status":"active","version":"3.1.1","tags":["javascript","gatsby","gatsby-plugin","typescript","graphql","graphql-codegen"],"last_verified":"Sun Jun 07","install":[{"cmd":"npm install gatsby-plugin-graphql-codegen","imports":["// In gatsby-config.js\nmodule.exports = {\n  plugins: [`gatsby-plugin-graphql-codegen`]\n}","// In .tsx files, types are auto-generated to default 'graphql-types.ts'\nimport { GatsbyTypes } from '../graphql-types';\n// Or with custom filename:\nimport { MyQueryQuery } from './gatsby-graphql';\n","const path = require('path');\nmodule.exports = {\n  plugins: [\n    {\n      resolve: `gatsby-plugin-graphql-codegen`,\n      options: {\n        codegen: true,\n        documentPaths: [\n          './src/**/*.{ts,tsx}',\n          path.join(process.cwd(), '.cache/fragments/*.js'),\n          'node_modules/gatsby-*/**/*.js'\n        ],\n        fileName: './gatsby-graphql-types.ts',\n        codegenDelay: 200,\n        failOnError: process.env.NODE_ENV === 'production',\n        codegenConfig: {},\n        codegenPlugins: [],\n        additionalSchemas: [],\n        pluckConfig: {\n          globalGqlIdentifierName: 'graphql',\n          modules: [{ name: 'gatsby', identifier: 'graphql' }]\n        }\n      }\n    }\n  ]\n};"]},{"cmd":"yarn add gatsby-plugin-graphql-codegen","imports":[]},{"cmd":"pnpm add gatsby-plugin-graphql-codegen","imports":[]}],"homepage":"https://github.com/d4rekanguok/gatsby-typescript#readme","github":"https://github.com/d4rekanguok/gatsby-typescript","docs":null,"changelog":null,"pypi":null,"npm":"gatsby-plugin-graphql-codegen","openapi_spec":null,"status_page":null,"smithery":null,"compatibility":null}