Integration · Vite

AHTML for Vite — single plugin, all endpoints

Add @ahtmljs/vite to your vite.config.ts and your SPA or SSR app exposes /ahtml, /llms.txt, /.well-known/ahtml.json, and an MCP descriptor with one plugin entry.

Step 1 · Install
npm install @ahtmljs/vite @ahtmljs/schema
Step 2 · Wire it up
// vite.config.ts
import { defineConfig } from 'vite';
import { ahtml } from '@ahtmljs/vite';

export default defineConfig({
  plugins: [
    ahtml({
      manifest: () => import('./src/ahtml.manifest'),
      snapshot: () => import('./src/ahtml.snapshot'),
    }),
  ],
});
Step 3 · Verify

Deploy. Then:

curl https://your-site.com/.well-known/ahtml.json
curl https://your-site.com/ahtml
curl https://your-site.com/llms.txt
Notes for Vite
  • Works with vanilla Vite SPA, SvelteKit dev mode, Astro, and Solid Start.
  • Dev-mode HMR refreshes the snapshot when your data file changes.
  • For prod, pair with your SSR/SSG host of choice — output is plain HTTP.

Three files. Three minutes.

npm: @ahtmljs/viteGitHubScore your site