Skip to main content
skill CX Codex

vanilla-lynx — Claude Code skill: Vanilla Lynx authoring

vanilla-lynx is a Claude Code skill that writes, reviews, and explains Vanilla Lynx code using Element PAPI. It targets build-free .lynxml files or Rspeedy application projects.

Apache-2.0 201 installs ★ 28 updated 2026-11-22

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add lynx-community/skills --skill vanilla-lynx -a claude-code
Open on GitHub

What vanilla-lynx does

The skill writes Vanilla Lynx source code directly with Element PAPI and runtime APIs without ReactLynx or JSX. It isolates UI mutations and __FlushElementTree() calls strictly to the main thread inside <script thread="main"> or main-thread.ts. Heavier computations, network requests via fetch, and NativeModules stay isolated in background threads with serializable payloads.

Browser and Node globals like window, document, and localStorage are prohibited, and Intl is not available in the runtime. For testing build-free .lynxml files, it serves them locally using npx http-server ., while Rspeedy projects run via rspeedy dev. It excludes device runtime inspection and bundle profiling, leaving device-side validation to lynx-devtool.

What it helps with

  • Vanilla Lynx authoring
  • build-free .lynxml single-file creation
  • Rspeedy project scaffolding and build workflows
  • main-thread Element PAPI tree management

Example prompts for the agent

  • Generate a standalone counter interface as a build-free .lynxml file.
  • Set up an Rspeedy project scaffold using Element PAPI without ReactLynx.
  • Review my main thread script and ensure background payloads remain serializable.

How to install vanilla-lynx

1Skills CLI (Vercel)

npx skills add lynx-community/skills --skill vanilla-lynx -a claude-code

2Manually: put the files in place

~/.claude/skills/vanilla-lynx/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/vanilla-lynx/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about vanilla-lynx

How to install vanilla-lynx in Claude Code?

Run npx skills add lynx-community/skills --skill vanilla-lynx -a claude-code. You can also place it manually at ~/.claude/skills/vanilla-lynx/SKILL.md.

What does vanilla-lynx do?

It authors and reviews Vanilla Lynx source code built on Element PAPI, producing either .lynxml documents or Rspeedy builds without ReactLynx.

What is required to run vanilla-lynx?

Testing .lynxml artifacts requires npx http-server ., project builds require Rspeedy, and device-level debugging relies on the external lynx-devtool skill.

Source text

SKILL.md · Apache-2.0
---
name: vanilla-lynx
description: |
  Author, review, or explain Vanilla Lynx source that directly uses Element PAPI, delivered as a build-free `.lynxml` artifact or an Rspeedy project, including related build and serving workflows. Excludes ReactLynx, Canvas/WebGL, standalone API/CSS lookups, device-side runtime debugging, and bundle analysis.
---

# Author Vanilla Lynx with Element PAPI

Use this skill to author Vanilla Lynx directly with Element PAPI and Lynx Runtime APIs, without ReactLynx or JSX. Treat build-free `.lynxml` and Rspeedy as peer output formats.

## Choose the Output Format

- Choose `.lynxml` when the user asks for a single file, build-free or directly loadable output, or explicitly says not to add a build step.
- Choose Rspeedy when the user asks for Rspeedy, a project scaffold or build configuration, or an app bundle produced by a build.
- Generic words such as app, page, card, or project do not select a format by themselves. If a complete authoring request lacks a distinguishing delivery or build requirement, or gives conflicting format signals, ask one concise clarification before generating the deliverable. Do not generate both complete formats unless the user requests both.
- For a focused source-level question or snippet request, answer the requested scope without forcing an output-format decision.

## Core Rules

- Rely only on Lynx-supported ECMAScript built-ins (note that `Intl` is not built in), Element PAPI, and Lynx runtime globals documented by this skill (`lynx`, `SystemInfo`, `console`, timers, `requestAnimationFrame`/`cancelAnimationFrame`, and background-only `NativeModules`/`fetch`). Do not use ReactLynx, JSX, virtual DOM, or undeclared browser/Node globals such as `window`, `document`, `navigator`, `localStorage`, or `performance` (use either `Date.now()` or the `requestAnimationFrame` callback timestamp consistently without mixing the two; `lynx.performance` is for trace/timing observation and has no `.now()`).
- For a complete authoring request, deliver the adapted artifact's full contents or write the requested file; never answer only with an example asset/reference path or instructions to read it. When authoring a build-free `.lynxml`, read `references/lynxml.md` and adapt the smallest matching template under `assets/examples/` (for example, `assets/examples/counter.lynxml` for a counter).
- Keep Element PAPI tree creation, mutation, lifecycle rendering, and UI updates in the main-thread source: `<script thread="main">` for `.lynxml` or `main-thread.ts` for Rspeedy. Never call Element PAPI APIs or `__FlushElementTree()` from the background-thread source; it only sends serializable patches for the main thread to apply and flush.
- Rely on the SDK flush for initial render; call `__FlushElementTree()` after later UI mutations.
- Add background-thread source only for heavier business logic, async work, timers, native calls, or data processing. Keep cross-thread payloads serializable.
- Use `lynx.getEngine()` only for engine-defined lifecycle events (`__RenderPage`, `__UpdatePage`, `__UpdateGlobalProps`, and `__DestroyLifetime`); never use it for app-defined thread-local or cross-thread events. Lifecycle handlers may ignore their event payload when the implementation does not need it, and registering empty `__UpdatePage` / `__UpdateGlobalProps` placeholders prevents unhandled Native host update callbacks. Keep stable handler references for long-lived and cross-thread listeners; remove them with the same context and event name during destroy instead of registering inline callbacks.
- Keep external bundle building and loading separate and background-only. External modules must be plain TypeScript or JavaScript; never use ReactLynx, JSX, or ReactLynx transforms in them. Match the rslib entry key to the first `loadScript` argument.

## Reference Routing

Read only the reference files needed for the current task. Preserve their explicit constraints rather
than replacing them with generic guidance.

| Task                                                              | Read                              |
| ----------------------------------------------------------------- | --------------------------------- |
| Author, assemble, or review a complete `.lynxml` document         | `references/lynxml.md`            |
| Author or review a complete Rspeedy project or build workflow     | `references/rspeedy-project.md`   |
| Build the main-thread Element PAPI tree or update UI              | `references/main-thread.md`       |
| Choose runtime event APIs or wire lifecycle events                | `references/event.md`             |
| Implement heavier logic in the background script                 | `references/background.md`        |
| Author or review CSS using Lynx styling and layout rules          | `references/style.md`             |
| Build background-thread code into an external bundle with rslib   | `references/external-build.md`    |
| Load or call a background-thread external bundle at runtime       | `references/external-runtime.md`  |

## Runtime Validation

Prepare a reachable artifact URL before handing off device validation to `lynx-devtool`:

- For a build-free `.lynxml`, do not run a build step. Run `npx http-server .` from the directory containing the unchanged artifact, keep the server running while Lynx Host opens a URL formed from one of the addresses printed by the server and the artifact filename, then stop it.
- For an Rspeedy project, use its configured development server (`rspeedy dev`) or build-and-serve workflow rather than a generic static server. Take the actual bundle URL from its output or checked-in configuration instead of guessing host, port, entry, output directory, or bundle path; keep the service running during validation, then stop it.

For device-side client discovery, opening the reachable URL, runtime inspection, console logs, screenshots, and interactions, use the `lynx-devtool` skill. Do not duplicate device-debugging workflow here or present `agent-lynx` as an artifact builder or server.

© lynx-community · Apache-2.0 · lynx-community/skills

Similar skills

All skills for Frontend and UI →
build-zoom-meeting-sdk-app official anthropics build-zoom-meeting-sdk-app is a Claude Code skill with guidance for embedding Zoom Meeting SDK in web and mobile apps, configuring JWT signatures, and fixing CSS conflicts. CX Codex +1 2,200installs wechat-miniprogram-skill Gourdbaby wechat-miniprogram-skill — a skill for Claude Code and five other AI coding agents that sets the agent as a native WeChat Mini Program expert in JavaScript. Kicks in whenever the task involves wx.* APIs, WXML, WXSS, or setData logic. CX Codex +1 1,500installs expo-react-native-javascript-best-practices Mindrally expo-react-native-javascript-best-practices is a Claude Code skill with JavaScript guidelines for Expo and React Native apps, covering functional components, Expo Router, and rendering performance. CX Codex +1 821installs react-native-expert https://github.com/Jeffallan react-native-expert — a skill for AI coding agents that helps build React Native and Expo apps: navigation, native modules, list performance, platform-specific code for iOS and Android. CX Codex +1 5,300installs expo-react-native-typescript Mindrally expo-react-native-typescript — a skill that hands your agent a rulebook for Expo, React Native and TypeScript work: file layout, navigation, state, testing. CX Codex +1 2,300installs capacitor-react capawesome-team capacitor-react guides coding agents through building mobile apps with Capacitor and React 18+. Helps write native feature hooks, configure deep links, and handle the Android back button. CX Codex +1 1,400installs

From the same set14

The whole set →
lynx-trace-record lynx-trace-record teaches AI agents to record Lynx performance traces via the trace_record CLI. Captures startup rendering, memory snapshots, and JS engine profiles. CX Codex +1 388installs lynx-ui A skill for building with lynx-ui: it picks the component, checks the public API in the repo's reference files and keeps the agent from inventing props. CX Codex +1 326installs lynx-debug-info-remapping lynx-debug-info-remapping maps Lynx function_id:pc_index error locations back to source lines with debug-info.json. Use it when a main-thread stack points into bytecode. CX Codex +1 325installs habitat-usage habitat-usage — a skill for Claude Code, Codex, Cursor and other platforms that configures Habitat to sync multi-repo dependencies and external assets via .habitat/DEPS and hab sync. CX Codex +1 253installs lynx-check-css-support lynx-check-css-support is a Claude Code skill that checks CSS property and value support across Lynx backends using bundled data. CX Codex +1 201installs lynx-api-docs lynx-api-docs — a skill for Claude Code and Codex that routes Lynx engine docs during TSX or TTML development. Prevents AI from assuming browser defaults. CX Codex +1 183installs lynx-a2ui lynx-a2ui — a skill for Claude Code that converts natural-language interface requests into A2UI v1.0 protocol messages. Outputs declarative JSON arrays directly for an A2UI renderer. CX Codex +1 170installs lynx-openui Writes OpenUI Lang v0.5 programs for the Lynx OpenUI renderer: static mobile screens, $state, Query/Mutation flows, streaming-friendly output. CX Codex +1 160installs

Project sponsors

Companies that keep this analytics open