UNPKG

astro

Version:

Astro is a modern site builder with web best practices, performance, and DX front-of-mind.

10 lines (9 loc) 333 B
import { errorMap } from "../errors/index.js"; import { createRelativeSchema } from "./schema.js"; async function validateConfig(userConfig, root, cmd) { const AstroConfigRelativeSchema = createRelativeSchema(cmd, root); return await AstroConfigRelativeSchema.parseAsync(userConfig, { errorMap }); } export { validateConfig };