Inertia Rails Setup logo

Inertia Rails Setup

Organization
inertia-rails
inertia-rails-setup

One-time project initializer for Inertia Rails skills. Detects stack and frontend framework (React/Vue/Svelte) from Gemfile and package.json, offers to install recommended deps (alba-inertia, js-routes, pagy, shadcn), and generates a CLAUDE.md section that configures which skill patterns apply. Use when first installing these skills, bootstrapping a new Inertia Rails project, or when the stack changes.

Overview

Publisherinertia-rails
Repositoryskills
Skill nameinertia-rails-setup
Stars
68
Forks
2
Bundled files
1
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • 1 bundled files

    Scripts, templates, and references the model can read while it works. Files are read-only and never executed.

  • Open source

    Published by inertia-rails on GitHub. Read the source before you install it.

Installation

Install the Inertia Rails Setup AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/inertia-rails/skills.git /tmp/skills
mkdir -p .claude/skills
cp -r /tmp/skills/skills/inertia-rails-setup .claude/skills/inertia-rails-setup
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Inertia Rails Setup in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Inertia Rails Setup on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Inertia Rails Setup is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Inertia Rails Project Setup

Detect stack, offer recommended deps, generate CLAUDE.md configuration.

Run once per project. Re-run when the stack changes.

NEVER:

  • Run setup without inertia_rails gem in Gemfile — all skills assume it exists. If missing, tell the user to install it first.
  • Overwrite existing ## Inertia Rails Stack in CLAUDE.md without reading it — the user may have manual customizations. Replace only the auto-generated block.
  • Add @/ resolve aliases to vite.config.tsvite-plugin-ruby already provides them. Only add to tsconfig.json.
  • Recommend alba-inertia if the project uses jbuilder AND the user hasn't expressed interest in switching — suggest it, but don't push. You CAN still suggest it if the project has blueprinter (alba is a direct upgrade path).
  • Generate CLAUDE.md blocks for skills the user doesn't have installed — saying "alba-inertia skill does NOT apply" is correct; saying "use alba-inertia" when the gem is absent is wrong.

Step 1: Detect Current Stack

Read Gemfile (NOT Gemfile.lock) and package.json and check for:

Look forMeans
inertia_rails gemInertia Rails installed (required)
@inertiajs/react in package.jsonReact frontend
@inertiajs/vue3 in package.jsonVue 3 frontend
@inertiajs/svelte in package.jsonSvelte frontend
alba-inertia gemConvention-based rendering active
alba + typelizer gems (no alba-inertia)Alba serialization without convention rendering
pagy gemPagy pagination
kaminari gemKaminari pagination
rspec-rails gemRSpec testing
js-routes gemTyped frontend path helpers
devise gemDevise authentication
pundit gemPundit authorization
action_policy gemAction Policy authorization
components.json in root existsshadcn installed (React: shadcn/ui, Vue: shadcn-vue, Svelte: shadcn-svelte)

Step 2: Recommend Missing Deps

Present detected stack, then offer deps that unlock skill features but aren't installed yet. Use AskUserQuestion with multiSelect for the recommendations.

Only recommend what's missing. Skip anything already detected in Step 1.

DepTypeInstall commandWhat it unlocks
alba + typelizer + alba-inertiagemsbundle add alba typelizer alba-inertiaConvention-based rendering, auto-generated TypeScript types from Ruby. Eliminates render inertia: { ... } boilerplate and manual TS interfaces. Unlocks alba-inertia skill.
js-routesgembundle add js-routesTyped path helpers (usersPath(), userPath(id)) in React — no more hardcoded URL strings.
pagygembundle add pagyLightweight pagination with Inertia-friendly metadata.
shadcn/ui (React)npxnpx shadcn@latest initPre-built React components adapted for Inertia. Unlocks shadcn-inertia skill.
shadcn-vue (Vue)npxnpx shadcn-vue@latest initPre-built Vue components adapted for Inertia. Unlocks shadcn-vue-inertia skill.
shadcn-svelte (Svelte)npxnpx shadcn-svelte@latest initPre-built Svelte components (bits-ui) adapted for Inertia. Unlocks shadcn-svelte-inertia skill.

Do NOT recommend gems the user clearly chose alternatives for (e.g., don't suggest Pagy if Kaminari is present, you can still suggest alba if the project has jbuilder or blueprinter).

Step 3: Install Opted-In Deps

Post-install scaffolding per dep:

  1. alba-inertia — also scaffold ApplicationResource:
    ruby
    # app/resources/application_resource.rb
    class ApplicationResource
      include Alba::Resource
      helper Typelizer::DSL
      helper Alba::Inertia::Resource
      include Rails.application.routes.url_helpers
    end
    And add Typelizer initializer:
    ruby
    # config/initializers/typelizer.rb
    Typelizer.configure do |config|
      config.output_dir = Rails.root.join("app/frontend/types/generated")
    end
  2. js-routes — run rails generate js_routes if the generator exists
  3. shadcn — framework-specific init:
    • React: npx shadcn@latest init
    • Vue: npx shadcn-vue@latest init
    • Svelte: npx shadcn-svelte@latest init After init, add @/ resolve aliases to tsconfig.json if not present

Step 4: Generate CLAUDE.md

Find or create CLAUDE.md in the project root. If ## Inertia Rails Stack exists, replace it (up to next ## or EOF). Otherwise, append.

MANDATORY — READ ENTIRE FILE before assembling the CLAUDE.md block: references/claude-md-templates.md (~90 lines) — all template blocks for each stack variant (serialization, UI, pagination, testing, routing, authorization). Pick one block per category based on the detected stack.

Do NOT load the templates file until Step 4 — Steps 1-3 determine which blocks to use.

Troubleshooting

SymptomCauseFix
npx shadcn@latest init fails with "No framework detected"Missing or misconfigured vite.config.tsEnsure vite-plugin-ruby is configured and tailwindcss is in package.json before running init
Typelizer generates types in wrong directoryMissing or wrong output_dir in initializerAdd config/initializers/typelizer.rb with config.output_dir = Rails.root.join("app/frontend/types/generated")
@/ imports not resolvingAliases added to vite.config.ts instead of tsconfig.jsonvite-plugin-ruby handles Vite aliases — only tsconfig.json needs @/ paths for TypeScript
CLAUDE.md has conflicting instructionsMultiple ## Inertia Rails Stack sectionsDelete duplicates — only one auto-generated block should exist
Skills reference alba-inertia but it's not installedSetup wasn't run, or alba wasn't selectedRe-run setup; CLAUDE.md should say "alba-inertia skill does NOT apply" if gem is absent
js_routes:generate failsjs-routes gem installed but generator not yet runRun rails generate js_routes first to create the config file, then rails js_routes:generate

Step 5: Summary

Tell the user:

  1. What was installed
  2. Which skills are relevant to their stack (and which to ignore)
  3. Review ## Inertia Rails Stack in CLAUDE.md — it takes precedence over generic examples in individual skills

Bundled files

The model reads these on demand while the skill is loaded. They are exposed as readable files and are never executed.

Frequently asked questions

What does the Inertia Rails Setup AI skill do?

One-time project initializer for Inertia Rails skills. Detects stack and frontend framework (React/Vue/Svelte) from Gemfile and package.json, offers to install recommended deps (alba-inertia, js-routes, pagy, shadcn), and generates a CLAUDE.md section that configures which skill patterns apply. Use when first installing these skills, bootstrapping a new Inertia Rails project, or when the stack changes.

Why use Inertia Rails Setup on TypingMind?

Because you install it once and use it with any model. Inertia Rails Setup is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Inertia Rails Setup in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/inertia-rails/skills/tree/main/skills/inertia-rails-setup. TypingMind reads its SKILL.md and bundles its files and installs it as a skill you can enable per chat.

Which AI models can use Inertia Rails Setup?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Inertia Rails Setup?

As many as you like. As long as a model supports skills, you can use Inertia Rails Setup with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Inertia Rails Setup AI skill free?

Yes. It is published on GitHub by inertia-rails under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇