@statekit-vue/shared
v0.4.0
Published
Shared types and metadata for StateKit state recipes.
Readme
@statekit-vue/shared
Shared types and metadata for StateKit state recipes.
@statekit-vue/shared is the source-of-truth package behind StateKit. Use it when you need typed ids, categories, layouts, tones, metadata lists, or lookup helpers without pulling in the Vue component layer.
Install
npm install @statekit-vue/sharedQuick Start
import {
priorityStateBlocks,
stateBlockMetaBySlug,
stateBlockMetaList,
} from "@statekit-vue/shared";
console.log(stateBlockMetaList.length);
console.log(stateBlockMetaBySlug["empty-search-state"].componentName);
console.log(priorityStateBlocks.map((block) => block.id));What It Exports
StateBlockId,ImplementedBlockId,StateCategory,StateTone,StateDensity, andStateLayoutStateAction,StateActionSlot,BaseStateProps, andStateBlockMetastateBlockMetaList,stateBlockMetaById, andstateBlockMetaBySlugimplementedBlockIds,priorityStateBlockIds,priorityStateBlocks, andisImplementedBlockId
Typical Uses
- Build docs tooling, recipe pickers, or internal registries from the same metadata used by the Vue package
- Drive analytics or routing from stable recipe ids and slugs
- Create custom wrappers around StateKit presets while keeping shared type safety
If you only want ready-to-use components, install @statekit-vue/vue for Vue apps or @statekit-vue/react for React apps instead.
Links
- Repository: https://github.com/gaoliuqing9178/StateKit
- Root docs and examples: https://github.com/gaoliuqing9178/StateKit#readme
- Release notes: https://github.com/gaoliuqing9178/StateKit/blob/main/CHANGELOG.md