evidence-anchor/vitest.config.ts

18 lines
667 B
TypeScript
Raw Normal View History

import { defineConfig } from "vitest/config";
import react from "@vitejs/plugin-react";
// Pure selector/resolution tests are node-safe; the scroll/highlight and PDF
// adapter tests touch the DOM, so the default environment is happy-dom. The
// react plugin lets the PDF adapter (.tsx) compile under test.
//
// The one shared-type dependency, `@citation-evidence/engine`, resolves through
// its package `exports` map (`./shared`) via the sibling-checkout link — no
// local alias needed. Nothing here imports `citation-evidence` internals.
export default defineConfig({
plugins: [react()],
test: {
environment: "happy-dom",
globals: false,
},
});