Custom GraphQL scalar types for GraphQL-Tools, providing Void, Integer, Float, String, Date, UUID, and JSON scalars with validation options. Current stable version is 1.3.2. This package is in maintenance mode with infrequent releases. Key differentiators include built-in validation (min/max, regex, UUID format) and struct validation for JSON scalars. Unlike other GraphQL scalar libraries, it integrates directly with graphql-tools' makeExecutableSchema pattern.
npm install graphql-tools-typesNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Quick example showing how to use GraphQLToolsTypes.Date custom scalar with graphql-tools makeExecutableSchema.
Always pass an options object with at least the 'name' property.
Use a custom scalar with a validate function in graphql-tools instead of relying on regex.
Ensure 'pure-uuid' is listed in your package.json dependencies.
Use default import: import GraphQLToolsTypes from 'graphql-tools-types';
Ensure values passed to Date fields are ISO 8601 strings.
Pass an options object: { name: 'MyType' }