@wpkernel/cli / createSchemasFragment
Function: createSchemasFragment()
ts
function createSchemasFragment(): IrFragment;Creates an IR fragment that loads configured JSON Schemas.
This fragment:
- Loads schemas declared in
config.schemasfrom disk - Hashes and normalises them
- Populates a shared SchemaAccumulator extension
- Exposes the accumulator entries on
ir.schemas
It does NOT attach schemas to resources; that is done on demand by the resources fragment via resolveResourceSchema, which may also add auto/inline schemas to the same accumulator.
