vue-with-rails

vue-with-rails is a skill for Claude Code, Codex from sandeepmvl/rails-skills. It costs 101 tokens per session (1,056 once invoked), scanned A, original, MIT.

A guide to adding Vue, a JavaScript interface framework, to a Ruby on Rails application. It covers Inertia.js, traditional APIs with single-page apps, and Vue 3's Composition API.

In plain words
What is it for?
Use it when building or reviewing a Rails application that needs Vue pages, client-side interactions, Inertia.js routing, or a separate Vue single-page frontend.
Why use it?
It helps choose an appropriate way to combine Vue and Rails without adding unnecessary complexity, especially when Rails already uses Hotwire.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Needs its repository: it reads a path above its own folder, which exists only inside the repository. The line is const pages = import.meta.glob("../Pages/**/*.vue", { eager: true }).

Good fit Use it when building or reviewing a Rails application that needs Vue pages, client-side interactions, Inertia.js routing, or a separate Vue single-page frontend.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/sandeepmvl/rails-skills
agentmods
npx agentmods add skills/sandeepmvl/rails-skills/25-vue-with-rails

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for vue-with-rails

README.md
[![agentmods](https://agentmods.dev/badge/skills/sandeepmvl/rails-skills/25-vue-with-rails/github.svg)](https://agentmods.dev/skills/sandeepmvl/rails-skills/25-vue-with-rails)
Your own site
<a href="https://agentmods.dev/skills/sandeepmvl/rails-skills/25-vue-with-rails"><img src="https://agentmods.dev/badge/skills/sandeepmvl/rails-skills/25-vue-with-rails/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for vue-with-rails

Your own site · 80×15
<a href="https://agentmods.dev/skills/sandeepmvl/rails-skills/25-vue-with-rails"><img src="https://agentmods.dev/badge/skills/sandeepmvl/rails-skills/25-vue-with-rails.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 101 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,056 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00101 $0.01056
Opus 5 $0.00051 $0.00528
Sonnet 5 $0.00020 $0.00211
Haiku 4.5 $0.00010 $0.00106

Measured 12d ago against content hash fbf62b359dc1, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

vue-with-rails scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 12d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/25-vue-with-rails/SKILL.md · 153 lines

How it starts

The opening of the file, as written. The whole thing — 153 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Vue with Rails

Same playbook as React: Inertia.js for most cases, classical API + SPA when justified. Vue 3 + Composition API is the current default.

The opinion

Inertia.js with the Vue adapter for most Rails + Vue apps. Classical API + SPA only when you have specific reasons. Vue 3, Composition API, vite_ruby. Don't add Vue to a Hotwire app unless you have a concrete need.

Decision matrix — same as React

See react-with-rails. The Inertia-vs-API+SPA decision is framework-agnostic.

Core patterns

Pattern 1: Inertia.js + Vue 3

# Gemfile
gem "inertia_rails"
yarn add @inertiajs/vue3 vue@^3
// app/frontend/entrypoints/application.js
import { createApp, h } from "vue"
import { createInertiaApp } from "@inertiajs/vue3"

createInertiaApp({
  resolve: name => {
    const pages = import.meta.glob("../Pages/**/*.vue", { eager: true })
    return pages[`../Pages/${name}.vue`]
  },
  setup({ el, App, props, plugin }) {
    createApp({ render: () => h(App, props) })
      .use(plugin)
      .mount(el)
  }
})
<!-- app/frontend/Pages/Posts/Index.vue -->
<script setup>
import { Link } from "@inertiajs/vue3"
defineProps({ posts: Array })
</script>

<template>
  <Link v-for="post in posts" :key="post.id" :href="`/posts/${post.id}`">
    {{ post.title }}
  </Link>
</template>
# Controller — same as React Inertia
class PostsController < ApplicationController
  def index
    render inertia: "Posts/Index", props: { posts: Post.all.as_json }
  end
end

Pattern 2: vite_ruby + Vue plugin

gem "vite_rails"
bin/vite install
yarn add @vitejs/plugin-vue
// vite.config.ts
import { defineConfig } from "vite"
import RubyPlugin from "vite-plugin-ruby"
import vue from "@vitejs/plugin-vue"

export default defineConfig({
  plugins: [RubyPlugin(), vue()]
})

HMR works out of the box.

Pattern 3: Pinia for client state (when needed)

For client-side state beyond what Inertia props give you:

Read the full file on GitHub · 153 lines

Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 12d ago First seen · 153 lines · 101 tokens per session scan A fbf62b359dc1

Subscribe to this mod's changes

vue-with-rails is a skill published in the GitHub repository sandeepmvl/rails-skills (21 stars, last pushed 3mo ago), licensed MIT. It adds 101 tokens to every session and 1,056 once invoked, about $0.0005 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

shadcn-svelte

Pre-built shadcn-svelte components for json-render Svelte apps. Use when working with @json-render/shadcn-svelte, adding standard UI components to a Svelte catalog, or building Svelte web UIs with shadcn-svelte + Tailwind CSS components.

vercel-labs/json-render · 63 tokens

create-site

Creates a new Power Pages code site (SPA) using React, Angular, Vue, or Astro. Guides through the full process from initial concept to deployed site: requirements discovery, scaffolding, component planning, design, implementation, validation, and deployment. Use when the user wants to create, build, or scaffold a new…

microsoft/power-platform-skills · 73 tokens

v3-create-crud

A page generator for standard create, read, update, and delete screens, commonly called CRUD screens. It uses Element Plus, a Vue user-interface library, to build tables, searches, pagination, forms, and delete confirmations.

un-pany/v3-admin-vite · 108 tokens

v3-use-composables

Documentation for reusable Vue functions in a project, covering device detection, asynchronous dropdown data, loading screens, pagination, routing, themes, page titles, and watermarks.

un-pany/v3-admin-vite · 137 tokens

moai-domain-uiux

UI/UX design systems specialist covering accessibility, icons, theming, design tokens, and user experience patterns. Use when working on design systems, WCAG compliance, ARIA patterns, or dark mode theming.

modu-ai/moai-adk · 49 tokens

moai-domain-frontend

Frontend development specialist covering React 19, Next.js 16, Vue 3.5, and modern UI/UX patterns with component architecture. Use when building web UIs, implementing components, optimizing frontend performance, or integrating state management.

modu-ai/moai-adk · 54 tokens