Dollie Editor SDK guide

Registry Extension

Reference for builder metadata embedded in shadcn registry items.

The x-dollie-editor extension adds page-builder metadata to a shadcn-compatible registry item.

Placement

Place the extension under the registry item's meta field:

{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "hero-newsletter",
  "type": "registry:block",
  "dependencies": ["@dollie_ai/editor"],
  "files": [],
  "meta": {
    "x-dollie-editor": {
      "version": 1,
      "sections": []
    },
    "tags": ["dollie-editor-ready"]
  }
}

Consumers may read the old top-level x-dollie-editor location for compatibility, but new items should use meta["x-dollie-editor"].

The package includes the JSON Schema at:

@dollie_ai/editor/schemas/x-dollie-editor.schema.json

Extension shape

Key Required Purpose
version Yes Extension contract version; currently 1
sections Yes Builder-ready section metadata
elements No Registered illustrations or widgets
templates No Portable page templates

Section entries use catalog-prefixed ids and may include the same fields and examples used by BuilderSectionDefinition.

Images are inline element references, so only illustrations and widgets appear in elements.

Templates

Generate template requirements with exportTemplate. Do not maintain requires by hand.

A consumer should check compatibility and use importTemplate to migrate and validate the page before applying it. Registry JSON remains untrusted input.

Discovery tag

Registry providers should add:

{
  "meta": {
    "tags": ["dollie-editor-ready"]
  }
}

The tag is a discovery signal. The x-dollie-editor block is the contract.

npm catalog marker

An npm catalog package uses a related package-level marker:

{
  "x-dollie-editor": {
    "catalog": "./src/catalog-export.ts"
  }
}

That marker lets dollie-editor discover and dollie-editor info locate the exported CatalogPackage.