agentleFS
GoogleKnown publishergoogle/xrblocks/skills/xb-build-app/SKILL.md

xb-build-app

Skill481 starsChanged 2 months agoApache-2.0View on GitHub

Build or extend a complete XR Blocks application. Use when the request concerns an app scaffold, a whole experience, several SDK areas, or an end-to-end simulator or XR handoff rather than one focused subsystem.

The file

We split this skill into the rules it gives an agent

4 rules. About 0 are common, 2 are distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈2

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Read ../../CONTEXT.md. Preserve an existing application's delivery model.

    line 23
  2. Distinctive:

    Use the engine-owned shape:

    line 40
  3. Distinctive:

    Use the focused skill when the slice needs spatial UI, interaction, world sensing, or AI.

    line 65
  4. Very specific:

    Keep normal startup on formFactor: 'auto'.

    line 77

≈ “Common” is an estimate: at least 1 in 5 of the 213,895 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Build an XR Blocks app

Deliver a handoff-ready vertical slice: the smallest complete experience a user can open, operate, and judge.

1. Write the experience contract

Resolve the first visible state, primary user action, observable result, target surface, headset input, desktop equivalent, permissions, assets, services, and unsupported states. Make reasonable spatial choices when the request leaves them open.

Complete this step when the slice can be stated as: “On surface S, the user does X, the app observes Y, and the experience becomes Z.”

2. Choose one executable foundation

Read ../../CONTEXT.md. Preserve an existing application's delivery model. For a new browser-module app, start from ../../templates/00_basic/. For a bundled TypeScript app, start from ../../templates/13_typescript_vite/. Choose a more focused template only when its feature is central.

For browser modules, read references/import-maps.md before changing the import map. Verify every XR Blocks symbol in ../../src/xrblocks.ts or an addon's public entry.

Complete this step when the app has one launch command, one entry URL, and one dependency graph in which every bare import resolves.

3. Build the complete slice

Use the engine-owned shape:

import * as THREE from 'three';
import * as xb from 'xrblocks';

class MainScript extends xb.Script {
  init() {
    this.add(new THREE.HemisphereLight(0xffffff, 0x666666, 3));
  }

  dispose() {
    // Release resources this script owns.
  }
}

const options = new xb.Options();
xb.add(new MainScript());
await xb.init(options);

Register scripts before initialization. Use engine-created objects only in or after init(). Put frame behavior in update() and release owned GPU, media, listener, timer, worker, and network resources in dispose().

Use the focused skill when the slice needs spatial UI, interaction, world sensing, or AI. Use the corresponding manual as concept authority and its linked template or sample as executable evidence. Addon-specific setup comes from that addon's README and public entry, not from an addon skill.

Complete this step when first load, primary action, observable result, and all normal unavailable states are implemented without placeholders.

4. Prepare simulator and XR paths

Read references/simulator-and-xr-handoff.md. Keep normal startup on formFactor: 'auto'. Supply an exact desktop simulator route for the primary action. Declare device permissions and session features before initialization. Share app state and scene setup across simulator and XR rather than creating separate applications.

Complete this step when each selected surface has an exact URL, entry action, input instructions, expected result, and named device-only limitations.

5. Prove and hand off the slice

Build or type-check the exact entry, run focused tests, and start the simulator route when the environment permits it. Check module resolution, initialization, first render, input affordances, handler registration, cleanup, and relevant console output. Verify intended public imports against the current entry even when the build is green.

Return the launch command and URL, target surface, input steps, expected result, required permissions or services, completed checks, and remaining real-device checks.

Finish when every available check passes and the user can begin meaningful testing without discovering setup, controls, or expected behavior from code.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.