Lines 554-594javascript
554 incremental: z.boolean().default(true),
556 * The enforced review-check matrix: which viewports, themes, zoom factors,
557 * and baseline routes every review must cover, and whether the verdict is
558 * gated on completing them.
560 * @default 5 common viewports, light theme, zooms [1, 2], routes ["/"], enforce true
562 checks: checksConfigSchema.prefault({})
566import path from "path";
567import { pathToFileURL } from "url";
568import { createJiti } from "jiti";
569function defineConfig(config) {
572async function loadConfig(cwd, configPath) {
573 const absolutePath = path.resolve(cwd, configPath ?? "revuiw.config.ts");
574 const jiti = createJiti(pathToFileURL(import.meta.url).href);
575 const loaded = await jiti.import(absolutePath, { default: true });
576 return uiReviewConfigSchema.parse(loaded);
MediumDynamic Require
Package source references dynamic require/import behavior.
dist/chunk-WBMYE2SU.jsView on unpkg · L574 579// src/review/suggestions.ts
580import { createHash } from "crypto";
581import { z as z2 } from "zod";
582var suggestionMarkerPrefix = "<!-- revuiw:suggestion ";
583var suggestionPayloadSchema = z2.object({
584 path: z2.string().min(1),
585 line: z2.number().int().positive(),
586 start_line: z2.number().int().positive().optional(),
587 side: z2.literal("RIGHT"),
588 start_side: z2.literal("RIGHT").optional(),
589 body: z2.string().min(1),
590 fingerprint: z2.string().min(1)
592function parseChangedLines(unifiedZeroDiff) {
593 const lines = /* @__PURE__ */ new Map();
594 for (const chunk of splitDiffByFile(unifiedZeroDiff)) {