-
-
Notifications
You must be signed in to change notification settings - Fork 0
Closed
Labels
area:ecosystemCross-repo initiatives and ecosystem-wide featuresCross-repo initiatives and ecosystem-wide featuresarea:wasmWASM/browser playground supportWASM/browser playground supporthigh-priorityHigh priority taskHigh priority taskpublishingPublishing and release tasksPublishing and release taskstype:featureNew feature or functionalityNew feature or functionality
Description
Goal
Provide npm package for using LUMOS in JavaScript/TypeScript projects without Rust toolchain.
Phase: 6.2 Tooling Ecosystem
Problem
JS/TS developers need Rust installed:
- ❌ Must install Cargo to use LUMOS
- ❌ Not idiomatic for JS projects
- ❌ Slower onboarding
Solution
Publish npm package with WASM or Node binary.
Installation
npm install @getlumos/cli
# or
yarn add @getlumos/cliUsage
import { generate } from '@getlumos/cli';
await generate('schema.lumos', {
outputRust: 'src/generated.rs',
outputTs: 'src/generated.ts',
});CLI:
npx lumos generate schema.lumosImplementation Options
Option 1: WASM (Preferred)
- Compile LUMOS core to WASM
- Works in Node.js and browsers
- No platform-specific binaries
Option 2: Native Binaries
- Ship binaries for each platform
- Faster than WASM
- More complex to maintain
Package Structure
@getlumos/cli/
├── dist/
│ ├── index.js # Main entry
│ ├── cli.js # CLI binary
│ └── lumos.wasm # WASM module
├── package.json
└── README.md
Features
- Generate schemas programmatically
- CLI via
npx lumos - Watch mode
- TypeScript types included
Success Criteria
- Published to npm as
@getlumos/cli - Works without Rust installed
- CLI and programmatic API
- TypeScript types
- Documentation
Documentation
-
docs/tools/npm-package.md -
ROADMAP.md- Mark Phase 6.2 complete ✅
Priority: High
Complexity: Medium-High
Timeline: 5-7 days
📌 Remember: Update ROADMAP.md after completing this issue!
Metadata
Metadata
Assignees
Labels
area:ecosystemCross-repo initiatives and ecosystem-wide featuresCross-repo initiatives and ecosystem-wide featuresarea:wasmWASM/browser playground supportWASM/browser playground supporthigh-priorityHigh priority taskHigh priority taskpublishingPublishing and release tasksPublishing and release taskstype:featureNew feature or functionalityNew feature or functionality