You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Shared language definitions and editor integrations for Wireweave DSL
Installation
npm install @wireweave/language-data
# or
pnpm add @wireweave/language-data
Features
Language Data - Component and attribute definitions
Monaco Integration - Full IntelliSense for Monaco Editor
CodeMirror Integration - Full IntelliSense for CodeMirror 6
Zero Dependencies - Standalone package
Usage
Basic Data
import{ALL_COMPONENTS,ATTRIBUTES,getComponent,getAttribute,getValidChildren,getComponentAttributes,}from'@wireweave/language-data';// Get component definitionconstpage=getComponent('page');console.log(page?.description);// Get attribute definitionconstgap=getAttribute('gap');console.log(gap?.type);// "number"// Get valid children for a componentconstchildren=getValidChildren('page');console.log(children.map(c=>c.name));// Get attributes for a componentconstattrs=getComponentAttributes('button');console.log(attrs.map(a=>a.name));