Sponsored byOutsenseAI that finds your next clients
SponsorGROUOutbound, LinkedIn content and leads for B2B teamsSponsorOutsenseAI that finds your next clientsAd+Your tool hereSeen by people installing AI tools@Weekly picksThe best new tools, one email a week

svelte-sitemap

Skill by bartholomej

Adds and configures sitemap.xml generation for SvelteKit apps using the svelte-sitemap Vite plugin. It suits developers who need a sitemap, per-page settings or hreflang alternates in a SvelteKit project.

  • Score 72
  • 361 stars
  • MIT
  • Updated
Works withClaude CodeClaude apps Antigravity CLI

Install svelte-sitemap

Built from the published package, never by AI.

git clone --depth 1 https://github.com/bartholomej/svelte-sitemap /tmp/svelte-sitemap && mkdir -p ~/.claude/skills && cp -r /tmp/svelte-sitemap/skills/svelte-sitemap ~/.claude/skills/svelte-sitemap

Run in your terminal. Claude Code loads skills from ~/.claude/skills automatically.

Step-by-step: install svelte-sitemap in Claude Code

Skills can run scripts on your machine. Some need an API key: check the README.

About

svelte-sitemap is an agent skill that adds and configures sitemap.xml generation for SvelteKit projects with the svelte-sitemap library. The library generates the sitemap from the prerendered HTML files of a SvelteKit build and runs at the end of vite build through its Vite plugin.

The skill tells the assistant to inspect the project first, checking the SvelteKit version, adapter, prerendering, trailing slashes and production domain. It then installs the library, adds the plugin with options such as domain, ignore, additional and transform, and checks the generated sitemap.xml. It is intended for developers working on SvelteKit sites who need a sitemap, SEO setup, per-page priority or hreflang alternates for multilingual sites.

Written from the project's SKILL.md and checked against it.

What it can do

  • Project inspectionChecks the SvelteKit version, adapter, prerendering and trailing slash setup before making changes.
  • Library installationInstalls svelte-sitemap as a dev dependency using the project's package manager.
  • Vite plugin setupAdds svelteSitemap() after sveltekit() in vite.config.ts and keeps existing options.
  • Option configurationSets domain, outDir, trailingSlashes, ignore, additional, changeFreq, resetTime, transform and debug.
  • Page exclusionLeaves out selected pages using names or glob patterns, and asks before excluding private-looking routes.
  • Per-page customizationUses the transform option for page priority, per-page lastmod and hreflang alternates.
  • Build verificationChecks the build log and the generated sitemap.xml for correct URLs, domain and excluded pages.
  • TroubleshootingLists common errors such as a wrong outDir, missing prerendering and a 404 sitemap on Cloudflare.

What you need

  • A SvelteKit project
  • Node.js 20 or newer
  • svelte-sitemap 4.0.6 or newer for SvelteKit 3
  • svelte-sitemap 4.1.0 or newer for the transform option

Try asking

  • Add a sitemap.xml to my SvelteKit project using svelte-sitemap
  • Exclude the admin and drafts pages from my SvelteKit sitemap
  • Add hreflang alternates to my multilingual SvelteKit sitemap

Good to know

  • Only prerendered pages are included, so other routes need prerendering or the additional option.
  • The build can succeed without a sitemap if outDir is wrong, so the output file must be checked.
  • Cloudflare Pages needs /sitemap.xml excluded from the adapter routes to avoid a 404.
  • Ignoring plain names matches flat page files only from version 4.1.1.

Security check

A

No download-and-run commands, hidden instructions or signs of sending keys out were found.

Checked automatically: skills/svelte-sitemap/SKILL.md. This looks for known risky patterns and is not a full audit. How grades work

Alternatives to svelte-sitemap

All alternatives →

Compare with box, n8n-mcp-tools-expert or citation-management

svelte-sitemap: common questions

Does svelte-sitemap work with SvelteKit 3?

Yes, but the source says SvelteKit 3 needs svelte-sitemap 4.0.6 or newer. In SvelteKit 3 the config is passed to sveltekit() in vite.config.ts instead of svelte.config.js.

Which pages does svelte-sitemap include?

The source says it only sees pages that are prerendered, so pages must be prerendered or listed in the additional option.

Can svelte-sitemap replace the old postbuild script?

Yes. The source says a legacy postbuild script or svelte-sitemap.config.ts should be moved into svelteSitemap({...}) unless the user wants to keep it.

How do I install svelte-sitemap?

Run the command above to copy the skill into ~/.claude/skills/. Claude Code picks it up automatically.

Is svelte-sitemap free?

The code is published under the MIT licence. The service it connects to may have its own pricing.

Is svelte-sitemap safe to use?

It scores 72 of 100. Grades: maintenance B, licence A, quality B. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.

What are alternatives to svelte-sitemap?

Similar skills: box, n8n-mcp-tools-expert, citation-management, exa-search.

svelte-sitemap Install

Add to stack

Loading.