{"id":49604,"library":"uniforms-react18-bridge-graphql","title":"uniforms GraphQL Bridge","description":"A GraphQL schema bridge for uniforms, a React library for building forms from schemas. This package allows you to generate forms automatically from a GraphQL schema. Version 0.0.2 is experimental; the stable version is part of the main uniforms package. Unlike JSON Schema bridges, this one leverages GraphQL type system. It ships TypeScript types and is part of the Vazco uniforms ecosystem. Release cadence follows the main uniforms repo.","status":"active","version":"0.0.2","language":"javascript","source_language":"en","source_url":"https://github.com/vazco/uniforms#master","tags":["javascript","form","forms","graphql","react","schema","validation","typescript"],"install":[{"cmd":"npm install uniforms-react18-bridge-graphql","lang":"bash","label":"npm"},{"cmd":"yarn add uniforms-react18-bridge-graphql","lang":"bash","label":"yarn"},{"cmd":"pnpm add uniforms-react18-bridge-graphql","lang":"bash","label":"pnpm"}],"dependencies":[],"imports":[{"note":"ESM-only; CJS require is not supported in this package version.","wrong":"const { GraphQLBridge } = require('uniforms-bridge-graphql');","symbol":"GraphQLBridge","correct":"import { GraphQLBridge } from 'uniforms-bridge-graphql';"},{"note":"TypeScript users should use type-only import for type checking.","wrong":null,"symbol":"GraphQLBridge types","correct":"import type { GraphQLBridge } from 'uniforms-bridge-graphql';"},{"note":"Default import is also supported and equivalent to named import.","wrong":null,"symbol":"default import","correct":"import GraphQLBridge from 'uniforms-bridge-graphql';"}],"quickstart":{"code":"import { GraphQLBridge } from 'uniforms-bridge-graphql';\nimport { buildASTSchema } from 'graphql';\n\nconst typeDefs = `\n  type Query {\n    user(id: ID!): User\n  }\n  type User {\n    id: ID!\n    name: String!\n    age: Int\n  }\n`;\n\nconst schema = buildASTSchema(parse(typeDefs));\nconst bridge = new GraphQLBridge(schema, {\n  type: 'User',\n  required: ['name']\n});\n\n// bridge is now usable with uniforms forms\nimport { AutoForm } from 'uniforms-react18';\nimport { AutoField } from 'uniforms-react18-material';\n\nconst MyForm = () => (\n  <AutoForm schema={bridge} onSubmit={console.log}>\n    <AutoField />\n  </AutoForm>\n);","lang":"typescript","description":"Shows how to create a GraphQLBridge from a GraphQL schema AST and use it with uniforms AutoForm."},"warnings":[{"fix":"Import and use buildASTSchema to convert SDL string to GraphQLSchema object before passing to bridge.","message":"The GraphQL schema must be built using buildASTSchema from graphql; bridge does not accept SDL string directly.","severity":"gotcha","affected_versions":">=0.0.0"},{"fix":"Always provide the 'type' option with the name of the GraphQL type (e.g., 'User').","message":"The bridge expects a 'type' option indicating the GraphQL type to use for form fields; omitting it may cause errors.","severity":"gotcha","affected_versions":">=0.0.0"},{"fix":"Watch the uniforms repository for updates and migration guides.","message":"This package is experimental and may be merged into the main uniforms package; breaking changes may occur.","severity":"deprecated","affected_versions":"0.0.x"}],"env_vars":null,"search_vec":"'0.0.2':31 'allow':20 'automat':25 'bridg':3,7,47 'build':14 'cadenc':67 'ecosystem':65 'experiment':33 'follow':68 'form':15,24,74,75 'generat':23 'graphql':2,5,28,51,76 'javascript':73 'json':45 'leverag':50 'librari':12 'main':41,70 'one':49 'packag':19,43 'part':38,60 'react':11,77 'releas':66 'repo':72 'schema':6,17,29,46,78 'ship':55 'stabl':35 'system':53 'type':52,57 'typescript':56,80 'uniform':1,9,42,64,71 'unlik':44 'valid':79 'vazco':63 'version':30,36","created_at":"2026-06-07T17:02:37.239444+00:00","updated_at":"2026-06-07T17:02:37.239444+00:00","problems":[{"fix":"Use buildASTSchema from the 'graphql' package to convert SDL to schema.","cause":"Passed an SDL string instead of a GraphQLSchema object.","error":"Error: You must provide a valid GraphQL schema to the GraphQLBridge constructor."},{"fix":"Add { type: 'YourTypeName' } as second argument to GraphQLBridge.","cause":"Missing the 'type' option in the bridge configuration.","error":"TypeError: Cannot read properties of undefined (reading 'fields')"}],"ecosystem":"npm","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":null,"cli_version":null,"type":"library","homepage":"https://github.com/vazco/uniforms/tree/master#readme","github":"https://github.com/vazco/uniforms#master","docs":null,"changelog":null,"pypi":null,"npm":"uniforms-react18-bridge-graphql","openapi_spec":null,"status_page":null,"smithery":null,"categories":["forms"],"base_url":null,"auth_type":null,"provenance":{"verified_status":null,"verified_at":null,"last_verified":"2026-06-07","next_check":"2026-09-05","install_tag":null}}