diff --git a/lib/compile/codegen/index.ts b/lib/compile/codegen/index.ts index 9d29055dc..5a6d1ee58 100644 --- a/lib/compile/codegen/index.ts +++ b/lib/compile/codegen/index.ts @@ -41,7 +41,11 @@ abstract class Node { } class Def extends Node { - constructor(private readonly varKind: Name, private readonly name: Name, private rhs?: SafeExpr) { + constructor( + private readonly varKind: Name, + private readonly name: Name, + private rhs?: SafeExpr + ) { super() } @@ -63,7 +67,11 @@ class Def extends Node { } class Assign extends Node { - constructor(readonly lhs: Code, public rhs: SafeExpr, private readonly sideEffects?: boolean) { + constructor( + readonly lhs: Code, + public rhs: SafeExpr, + private readonly sideEffects?: boolean + ) { super() } @@ -84,7 +92,12 @@ class Assign extends Node { } class AssignOp extends Assign { - constructor(lhs: Code, private readonly op: Code, rhs: SafeExpr, sideEffects?: boolean) { + constructor( + lhs: Code, + private readonly op: Code, + rhs: SafeExpr, + sideEffects?: boolean + ) { super(lhs, rhs, sideEffects) } @@ -211,7 +224,10 @@ class Else extends BlockNode { class If extends BlockNode { static readonly kind = "if" else?: If | Else - constructor(private condition: Code | boolean, nodes?: ChildNode[]) { + constructor( + private condition: Code | boolean, + nodes?: ChildNode[] + ) { super(nodes) } @@ -331,7 +347,11 @@ class ForIter extends For { class Func extends BlockNode { static readonly kind = "func" - constructor(public name: Name, public args: Code, public async?: boolean) { + constructor( + public name: Name, + public args: Code, + public async?: boolean + ) { super() } diff --git a/lib/types/index.ts b/lib/types/index.ts index 123d9df16..054b10f6f 100644 --- a/lib/types/index.ts +++ b/lib/types/index.ts @@ -138,9 +138,12 @@ export interface DataValidateFunction { } export interface SchemaValidateFunction { - (schema: any, data: any, parentSchema?: AnySchemaObject, dataCxt?: DataValidationCxt): - | boolean - | Promise + ( + schema: any, + data: any, + parentSchema?: AnySchemaObject, + dataCxt?: DataValidationCxt + ): boolean | Promise errors?: Partial[] } diff --git a/package.json b/package.json index 8ddabaa04..04ada38c4 100644 --- a/package.json +++ b/package.json @@ -64,7 +64,7 @@ "uri-js": "^4.4.1" }, "devDependencies": { - "@ajv-validator/config": "^0.3.0", + "@ajv-validator/config": "^0.4.0", "@rollup/plugin-commonjs": "^25.0.7", "@rollup/plugin-json": "^6.1.0", "@rollup/plugin-node-resolve": "^15.2.3", @@ -98,7 +98,7 @@ "module-from-string": "^3.3.0", "node-fetch": "^3.3.2", "nyc": "^15.1.0", - "prettier": "^2.8.8", + "prettier": "3.0.3", "re2": "^1.20.9", "rollup": "^2.79.1", "rollup-plugin-terser": "^7.0.2",