banira manifest

Generate a Custom Elements Manifest (custom-elements.json) — the ecosystem-standard descriptor that powers IDE autocomplete, Storybook controls and template type-checking.

Usage

$ banira manifest <files...> [options]

Arguments

ArgumentDescription
<files...>Component source files to analyze.

Options

OptionDescription
-o, --output <path>Write the output to a file instead of stdout.
--mdEmit Markdown API documentation instead of JSON.
--validateValidate the generated manifest and print a report (exit 1 on errors). Also checks the official CEM JSON Schema when the optional ajv dependency is installed.
--link-packagePoint the nearest package.json’s customElements field at the written manifest (the convention IDEs and Storybook use to auto-discover it).

Examples

write the manifest
$ banira manifest src/*.ts -o custom-elements.json
Markdown API tables for a README
$ banira manifest src/*.ts --md -o API.md
write + link it from package.json
$ banira manifest src/*.ts -o custom-elements.json --link-package

Notes

Attributes are read from observedAttributes, properties/methods from public class members, events from new CustomEvent(...), and slots / CSS parts / CSS custom properties from class jsdoc tags (@slot, @csspart, @cssprop, @fires). Members marked @deprecated carry the note through; @internal / @ignore members are omitted. An attribute backed by a string-literal union ('sm' | 'md' | 'lg') captures its allowed values, which flow through to the .d.ts union, editor autocomplete and Storybook select options. See Authoring components for the full tag reference.