mcpField
R
raycast-extensions

raycast-extensions

github.com/alexi-buildDevelopment1755 installsUpdated 25w ago
Repository

About raycast-extensions

A skill for building Raycast extensions with React, TypeScript, and the Raycast API. It guides implementation through API references, UI patterns, data handling, and checks for restricted APIs.

Key features

  1. 01React and TypeScript implementation guidance
  2. 02Raycast API reference lookup
  3. 03List, Grid, Detail, and Form patterns
  4. 04Cache and LocalStorage usage guidance
  5. 05Restricted API access checks

Use cases

  1. 01Build a searchable extension interface
  2. 02Add forms and detail views
  3. 03Choose storage for transient or persistent data
  4. 04Implement AI or browser features with access checks

Install

Copy the command and run it in a terminal.

$npx skills add https://github.com/alexi-build/raycast-extensions-skill --skill raycast-extensions

After installing, type/raycast-extensionsin Claude Code to confirm it loaded.

Bundled files

References and scripts installed along with SKILL.md.

examples.md
references/api/
alert.md
clipboard.md
command-related-utilities.md
actions.md
action-panel.md
browser-extension.md
caching.md
colors.md
ai.md
detail.md
environment.md
keyboard.md
feedback.md
hud.md
grid.md
navigation.md
pikachu-1.md
pikachu-3.md
pikachu-2.md
form.md
menu-bar-commands.md
icons-images.md
oauth.md
list.md
pikachu-4.md
preferences.md
pikachu.md
system-utilities.md
storage.md

Details

From the project README

Raycast Extensions Skill

Build powerful extensions with React, TypeScript, and the Raycast API.

Repository Conventions

  • When updating CHANGELOG.md for the Raycast extensions repository, always use {PR_MERGE_DATE} as the date placeholder.
  • Never write a literal calendar date in CHANGELOG.md.

Quick Start (Agent Workflow)

Follow these steps when tasked with implementing or fixing Raycast features:

  1. Identify the core component: Determine if the UI needs a List, Grid, Detail, or Form.
  2. Consult Reference: Open and read the corresponding file in references/api/ (e.g., references/api/list.md).
  3. Use Defaults:
    • Feedback: Use showToast for Loading/Success/Failure. Use showHUD only for quick background completions.
    • Data: Use Cache for frequent/transient data, LocalStorage for persistent user data.
    • Access: Always check environment.canAccess(AI) or environment.canAccess(BrowserExtension) before use.
    • Changelog: When updating CHANGELOG.md for the Raycast extensions repository, always use {PR_MERGE_DATE} as the date placeholder. Never write a literal calendar date.
  4. Implementation: Provide a concise implementation using @raycast/api components.
  5. Citing: Link back to the specific references/api/*.md file you used.

Cookbook Patterns

1. List & Grid (Searchable UI)

Use List for text-heavy data and Grid for image-heavy data.

<List isLoading={isLoading} searchBarPlaceholder="Search items..." throttle>
  <List.Item
    title="Item Title"
    subtitle="Subtitle"
    accessories={[{ text: "Tag" }]}
    actions={
      <ActionPanel>
        <Action.Push title="View Details" target={<Detail markdown="# Details" />} />
        <Action.CopyToClipboard title="Copy" content="value" />
      </ActionPanel>
    }
  />
</List>
2. Detail (Rich Markdown)

Use for displaying long-form content or item details.

<Detail
  isLoading={isLoading}
  markdown="# Heading\nContent here."
  metadata={
    <Detail.Metadata>
      <Detail.Metadata.Label title="Status" text="Active" icon={Icon.Checkmark} />
    </Detail.Metadata>
  }
/>
3. Form (User Input)

Always include a SubmitForm action.

<Form
  actions={
    <ActionPanel>
      <Action.SubmitForm onSubmit={(values) => console.log(values)} />
    </ActionPanel>
  }
>
  <Form.TextField id="title" title="Title" placeholder="Enter title" />
  <Form.TextArea id="description" title="Description" />
</Form>
4. Feedback & Interactivity

Prefer showToast for most feedback.

// Success/Failure
await showToast({ style: Toast.Style.Success, title: "Success!" });

// HUD (Overlay)
await showHUD("Done!");
5. Data Persistence

Use Cache for performance, LocalStorage for persistence.

// Cache (Sync/Transient)
const cache = new Cache();
cache.set("key", "value");

// LocalStorage (Async/Persistent)
await LocalStorage.setItem("key", "value");
6. AI & Browser Extension (Restricted APIs)

Always wrap in environment.canAccess checks.

if (environment.canAccess(AI)) {
  const result = await AI.ask("Prompt");
}

if (environment.canAccess(BrowserExtension)) {
  const tabs = await BrowserExtension.getTabs();
}

Additional Resources

API Reference Tree

Examples

For end-to-end examples combining multiple components and APIs, see examples.md.

Comments

Markdown supported