PluginBench
Skill
Official
Pass
Audit score 90

jotai

vercel-labs/json-render

How to install jotai

npx skills add https://github.com/vercel-labs/json-render --skill jotai
Claude Code
Cursor
Windsurf
Cline
Full instructions (SKILL.md)

Source of truth, from vercel-labs/json-render.


name: jotai description: Jotai adapter for json-render's StateStore interface. Use when integrating json-render with Jotai for state management via @json-render/jotai.

@json-render/jotai

Jotai adapter for json-render's StateStore interface. Wire a Jotai atom as the state backend for json-render.

Installation

npm install @json-render/jotai @json-render/core @json-render/react jotai

Usage

import { atom } from "jotai";
import { jotaiStateStore } from "@json-render/jotai";
import { StateProvider } from "@json-render/react";

// 1. Create an atom that holds the json-render state
const uiAtom = atom<Record<string, unknown>>({ count: 0 });

// 2. Create the json-render StateStore adapter
const store = jotaiStateStore({ atom: uiAtom });

// 3. Use it
<StateProvider store={store}>
  {/* json-render reads/writes go through Jotai */}
</StateProvider>

With a Shared Jotai Store

When your app already uses a Jotai <Provider> with a custom store, pass it so both json-render and your components share the same state:

import { atom, createStore } from "jotai";
import { Provider as JotaiProvider } from "jotai/react";
import { jotaiStateStore } from "@json-render/jotai";
import { StateProvider } from "@json-render/react";

const jStore = createStore();
const uiAtom = atom<Record<string, unknown>>({ count: 0 });

const store = jotaiStateStore({ atom: uiAtom, store: jStore });

<JotaiProvider store={jStore}>
  <StateProvider store={store}>
    {/* Both json-render and useAtom() see the same state */}
  </StateProvider>
</JotaiProvider>

API

jotaiStateStore(options)

Creates a StateStore backed by a Jotai atom.

OptionTypeRequiredDescription
atomWritableAtom<StateModel, [StateModel], void>YesA writable atom holding the state model
storeJotai StoreNoThe Jotai store instance. Defaults to a new store. Pass your own to share state with <Provider>.

Related skills

More from vercel-labs/json-render and the wider catalog.

MCmcp logo

mcp

Official
vercel-labs/json-render

MCP Apps integration for json-render. Use when building MCP servers that render interactive UIs in Claude, ChatGPT, Cursor, or VS Code, or when integrating json-render with the Model Context Protocol.

1.2k installsAudited
NEnext logo

next

Official
vercel-labs/json-render

Next.js renderer for json-render that turns JSON specs into full Next.js applications with routes, layouts, SSR, and metadata. Use when working with @json-render/next, building Next.js apps from JSON specs, or creating AI-generated multi-page applications.

865 installsAudited
REreact logo

react

Official
vercel-labs/json-render

React renderer that converts JSON specs into React component trees.

3.1k installsAudited
REreact-email logo

react-email

Official
vercel-labs/json-render

React Email renderer for json-render that turns JSON specs into HTML or plain-text emails using @react-email/components and @react-email/render. Use when working with @json-render/react-email, building transactional or marketing emails from JSON, creating email catalogs, rendering AI-generated email specs, or when the user mentions react-email, HTML email, or transactional email.

831 installsAudited
REreact-native logo

react-native

Official
vercel-labs/json-render

React Native renderer for json-render that turns JSON specs into native mobile UIs. Use when working with @json-render/react-native, building React Native UIs from JSON, creating mobile component catalogs, or rendering AI-generated specs on mobile.

1.1k installsAudited
REreact-pdf logo

react-pdf

Official
vercel-labs/json-render

Generate PDF documents from JSON specs using React components and @react-pdf/renderer.

1.5k installsAudited