Manifest API Reference

The ultimate guide to building with Manifest's modular architecture.

🚀 Getting Started

Install Manifest via npm or yarn in your project directory.

$ npm create manifest@latest

This will create a new project scaffold with everything you need to start building.

🔧 Key Concepts

Modular Components

Build with reusable, self-contained modules.

Realtime APIs

Synchronize state across devices instantly.

Cross-Platform Sync

Deploy to Web, Mobile, and Desktop from one codebase.

📚 API Reference

Module System (manifest/modules.js)

// Create a new module
const myModule = Manifest.Module.create({
  name: 'ui-kit',
  components: {
    button: '@manifest/core/Button'
  }
});

// Register the module
Manifest.Registry.register(myModule);

Modules are the fundamental building blocks of Manifest. They encapsulate functionality, resources, and dependencies.

Tip: Use Manifest.Registry to manage and discover available modules in your system.

Realtime Collaboration (manifest/realtime.js)

// Initialize shared state
const doc = Manifest.Realtime.create({
  id: 'project-document',
  type: 'json',
  initial: { title: 'My Project' }
});

// Subscribe to changes
doc.on('change', (delta) => {
  console.log('Document updated:', delta);
});

Realtime features enable collaborative editing experiences across all platforms. Changes propagate instantly with operational transformation.

Note: All real-time operations are synchronized through manifest-server by default.