@apollo/client-graphql-codegen@1.0.0-alpha.0
📦 apollo-client
✨ 1 features🔧 4 symbols
Summary
A new GraphQL Codegen plugin '@apollo/client-graphql-codegen/local-state' adds generated resolver types for LocalState, enabling type‑safe local resolvers.
Migration Steps
- Install @apollo/client-graphql-codegen package.
- Add the plugin '@apollo/client-graphql-codegen/local-state' to your codegen configuration as shown.
- Configure plugin options such as nonOptionalTypename, baseTypesPath, and contextType if needed.
- Use the generated Resolvers type when constructing a new LocalState instance.
- Prefer using your local schema file for the schema option to avoid generating resolver types for the remote schema.
✨ New Features
- Introduce @apollo/client-graphql-codegen/local-state plugin to generate resolver types for LocalState, providing a Resolvers type for type‑safe local resolvers.
🔧 Affected Symbols
LocalStateResolvers@apollo/client-graphql-codegen/local-stateCodegenConfig