@compact-design/core 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,22 @@
1
+ import { type RepairIssue } from "./lint";
2
+ import { isPatchDocument } from "./normalize";
3
+ import { type PatchResult } from "./patch";
4
+ import { schema } from "./schema";
5
+ import type { InternalDocument, InternalPatchDocument } from "./types";
6
+ export interface ValidationResult {
7
+ valid: boolean;
8
+ issues: RepairIssue[];
9
+ document?: InternalDocument;
10
+ patch?: InternalPatchDocument;
11
+ }
12
+ export declare function parse(source: string): unknown;
13
+ export declare function normalize(value: unknown): InternalDocument;
14
+ export declare function normalizePatch(value: unknown): InternalPatchDocument;
15
+ export declare function validate(value: unknown): ValidationResult;
16
+ export declare function lint(value: InternalDocument): RepairIssue[];
17
+ export declare function applyPatch(document: InternalDocument, patch: InternalPatchDocument): PatchResult;
18
+ export { isPatchDocument, schema };
19
+ export { indexDocument } from "./references";
20
+ export type { DocumentIndex } from "./references";
21
+ export type { PatchResult, RepairIssue };
22
+ export type * from "./types";