@maayan-albert/moab-sdk
v1.0.6
Published
Moab SDK - A JavaScript/TypeScript SDK
Readme
moab-sdk
A JavaScript/TypeScript SDK for Moab.
Installation
pnpm add @maayan-albert/moab-sdk
# or
npm install @maayan-albert/moab-sdkUsage
SDK Usage
const MoabSDK = require('@maayan-albert/moab-sdk');
const sdk = new MoabSDK({
// your options here
});
sdk.hello();UI Components (React TypeScript)
import React from 'react';
import { Button, Card, Input } from '@maayan-albert/moab-sdk/components';
const MyApp: React.FC = () => {
return (
<div>
<Card title="Welcome">
<Input label="Name" placeholder="Enter your name" />
<Button variant="primary" onClick={() => alert('Clicked!')}>
Submit
</Button>
</Card>
</div>
);
};Development
# Install dependencies
pnpm install
# Run the SDK example
pnpm start
# or
pnpm example
# Run the component demo (dev server with hot reload)
pnpm demo
# This will start a Vite dev server (usually http://localhost:5173) where you can preview all UI components
# Build the demo for production
pnpm run demo:build
# Preview the production build
pnpm run demo:preview
# Type check
pnpm type-check
# Build
pnpm run build
# Test
pnpm testPreviewing Components
To preview and test the UI components, run:
pnpm demoThis starts a Vite development server (typically at http://localhost:5173) with:
- ⚡ Fast hot module replacement (HMR) - changes appear instantly
- 🔥 Zero-config setup - works out of the box
- 📦 Automatic TypeScript/React bundling
- 🎨 See all components in action with live reload
You can:
- See all components in action
- Test different variants and props
- Interact with components to verify behavior
- Edit components and see changes instantly
- Use this as a reference for implementing components in your apps
License
MIT
