vite-iconify-svgmap

vite-iconify-svgmap is a skill for Claude Code, Codex from stephansama/packages. It costs 97 tokens per session (1,416 once invoked), scanned A, original, MIT.

A Vite plugin that builds SVG sprite maps from Iconify icon packs while your app is built. It also integrates with Astro and SvelteKit.

In plain words
What is it for?
It is for adding static or render-time Iconify icons to Vite, Astro, or SvelteKit applications.
Why use it?
It avoids writing separate SVG files for every icon and keeps track of which icons are used in memory. Only the finished sprite maps are written to disk.

Skill for Claude CodeCodex

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

Good fit It is for adding static or render-time Iconify icons to Vite, Astro, or SvelteKit applications.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/stephansama/packages/vite-iconify-svgmap
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add stephansama/packages --skill vite-iconify-svgmap
Clone the repo
git clone --depth 1 https://github.com/stephansama/packages

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 vite-iconify-svgmap

README.md
[![agentmods](https://agentmods.dev/badge/skills/stephansama/packages/vite-iconify-svgmap/github.svg)](https://agentmods.dev/skills/stephansama/packages/vite-iconify-svgmap)
Your own site
<a href="https://agentmods.dev/skills/stephansama/packages/vite-iconify-svgmap"><img src="https://agentmods.dev/badge/skills/stephansama/packages/vite-iconify-svgmap/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 vite-iconify-svgmap

Your own site · 80×15
<a href="https://agentmods.dev/skills/stephansama/packages/vite-iconify-svgmap"><img src="https://agentmods.dev/badge/skills/stephansama/packages/vite-iconify-svgmap.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 97 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,416 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.00097 $0.01416
Opus 5.5 $0.00039 $0.00566
Sonnet 5.5 $0.00019 $0.00283
Haiku 4.5 $0.00010 $0.00142

Measured 20d ago against content hash ca3748695dc2, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

vite-iconify-svgmap 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 20d 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.

core/vite-iconify-svgmap/skills/vite-iconify-svgmap/SKILL.md · 162 lines

How it starts

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

vite-iconify-svgmap

Generates SVG sprite maps from Iconify icon packs. Icon usage is tracked in memory; the only files written are the final sprites.

Setup

  1. Install the plugin and at least one @iconify-json/* pack:
pnpm add -D @stephansama/vite-iconify-svgmap @iconify-json/mdi
  1. Astro: add the integration to astro.config.mjs:
import iconifySvgmap from "@stephansama/vite-iconify-svgmap/astro/integration";
import { defineConfig } from "astro/config";

export default defineConfig({
  integrations: [iconifySvgmap()],
});

SvelteKit: add the plugins from @stephansama/vite-iconify-svgmap/svelte/integration after sveltekit() in vite.config.js:

import iconifySvgmap from "@stephansama/vite-iconify-svgmap/svelte/integration";
import { sveltekit } from "@sveltejs/kit/vite";
import { defineConfig } from "vite";

export default defineConfig({ plugins: [sveltekit(), iconifySvgmap()] });

Plain Vite: add iconifySvgmap() from @stephansama/vite-iconify-svgmap to plugins.

  1. Add the virtual module types to tsconfig.json:
{ "compilerOptions": { "types": ["@stephansama/vite-iconify-svgmap/client"] } }

Core Patterns

Static imports (preferred)

---
import home from "virtual:iconify-svgmap/mdi/home";
---

<svg width="24" height="24" aria-hidden="true"><use href={home}></use></svg>

The default export is the sprite href (/_astro/mdi.<hash>.svg#home in builds). Unknown packs or icons fail the build.

Icons only known while rendering

---
import { getIcon } from "virtual:iconify-svgmap";

const href = getIcon(entry.data.pack, entry.data.icon);
---

<svg width="24" height="24" aria-hidden="true"><use href={href}></use></svg>

getIcon is synchronous. It registers the icon in memory and returns /_iconify/<pack>.svg?v=<build>#<icon>. The Astro integration writes those sprites in astro:build:done; without Astro call writeSprites(clientOutDir) after rendering.

Icon components (astro, svelte)

Read the full file on GitHub · 162 lines

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. 20d ago First seen · 162 lines · 97 tokens per session scan A ca3748695dc2

Subscribe to this mod's changes

vite-iconify-svgmap is a skill published in the GitHub repository stephansama/packages (5 stars, last pushed 8d ago), licensed MIT. It adds 97 tokens to every session and 1,416 once invoked, about $0.0004 per session on Opus 5.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-09-27.

Related

Other skills, from other repositories

opendia-harness

Install, configure, and troubleshoot OpenDia for Grok Build (and other MCP harnesses). Use when setting up the plugin, config.toml MCP entry, ports, extension disconnects, tool timeouts, or tunnel mode.

aeonfun/opendia · 52 tokens

video-shot-demos

A workflow for creating animated HTML pages, one page per video shot, lesson segment, or narrated scene. It combines a shared player structure with different visual designs for each shot.

Unclecheng-li/AI_Animation · 166 tokens

opendia

Drive the user's real browser through OpenDia MCP (logged-in sessions, cookies, wallets, bookmarks, history). Use when automating Chrome/Firefox for social posts, form fills, multi-tab research, local webapp testing, or any task that needs the user's existing browser profile — not a disposable cloud browser.

aeonfun/opendia · 66 tokens

hero-slider-settle

A render-quality slider rises past the target, corrects, then settles on 75%. Function: range control / preference set.

Unclecheng-li/AI_Animation · 0 tokens

npm-security

Prevent JavaScript/TypeScript projects from supply-chain attacks across package managers like npm, pnpm, yarn, bun, and deno. Use whenever planning, installing, updating dependencies or configuring package managers.

bodadotsh/npm-security-best-practices · 43 tokens

exploring-autocapture-events

Guides exploration of $autocapture events captured by posthog-js to understand user interactions, find CSS selectors (especially data-attr attributes), evaluate selector uniqueness, query matching clicks ad-hoc, and create actions. Use when the user asks about autocapture data, wants to find what users are clicking…

PostHog/posthog · 127 tokens