@fragments-sdk/govern
v0.3.3
Published
AI UI governance engine — validate AI-generated UI specs against configurable policies
Downloads
298
Maintainers
Readme
@fragments-sdk/govern
Source-available. This package is distributed publicly on npm under FSL-1.1-MIT; source stays private. Contribute by filing an issue at https://github.com/fragments-sdk/fragments/issues.
AI UI governance engine — validates AI-generated UI specs and source files against configurable design system policies. Ships 8 validators (safety, a11y, tokens, components, props-registry, compound-children, canonical-usage, brand) with two presets (fragments, universal).
Install
npm install @fragments-sdk/governProgrammatic use
import { scan, loadPolicy } from '@fragments-sdk/govern';
const policy = await loadPolicy('./fragments.governance.json');
const findings = await scan({ policy, cwd: process.cwd() });See the Fragments documentation for policy schema and validator details.
License
FSL-1.1-MIT. Source is private; contributions accepted via the issue tracker linked above.
