Skip to content

PACK_ID_GRAMMAR

const PACK_ID_GRAMMAR: RegExp

Defined in: types/src/pack.ts:18

Grammar for a pack id: <scope>/<name>, mirroring npm scoping. Internal packs use the cadence scope (e.g. cadence/core-skills); @scope/name is reserved for third-party packs later — same grammar, no special-casing. See docs/packs-design.md §5 I-1.

Exported so resolvers can validate a config-supplied id before using it to build a filesystem path — a config id never passes through PackManifestZ itself (that only validates the manifest’s own id field, a different string), so without this a malformed config.packs.enabled entry (e.g. ../../etc) would reach a path join unchecked.