mirror of
https://github.com/hanzoai/ui.git
synced 2026-11-21 00:18:41 +00:00
@hanzo/vite 0.1.5 adds site(): the App Router's file conventions (layouts, groups, dynamic and rest segments, generateStaticParams, metadata, not-found, route.ts GET, opengraph-image, robots, sitemap) rendered as React Server Components through @vitejs/plugin-rsc and written as HTML to out/. Pages import @hanzo/vite/link, /navigation, /dynamic and /metadata in place of next/*. mdx() reads posts with front matter, gfm, [#id] heading ids and a toc export. The head is resolved by the App Router's rules and written in its order; a key it does not render throws. Measured on hanzo.blog: 712 pages with identical text, head tags and <html lang dir> against its Next export. @hanzo/og 1.0.1 draws with satori 0.12.2, the layout its images were drawn against, and loads resvg from its own install at run time, since a bundler cannot carry a native addon. It no longer peers on next. The lockfile is regenerated over the whole workspace: main's predated @hanzo/commerce 7.9.1. Claude-Session: https://claude.ai/code/session_015XYKLnoSseGhXKoeBiFtQF
11 lines
553 B
TypeScript
11 lines
553 B
TypeScript
import { defineConfig } from "vitest/config"
|
|
|
|
// A package whose `test` script is `vitest run` needs its OWN config. Without
|
|
// one vitest walks up to the root workspace file and resolves its relative
|
|
// entries against THIS directory, so it looks for a config here, does not find
|
|
// it, and fails at startup before a single test runs — which reads as a broken
|
|
// suite rather than a missing file. Pure config folding: node, no DOM.
|
|
export default defineConfig({
|
|
test: { environment: "node", include: ["src/**/*.test.ts", "src/**/*.test.tsx"] },
|
|
})
|