Skip to main content

Module strict

Module strict 

Source
Expand description

strictASTSchema (packages/zero-protocol/src/ast.ts), for ASTs a client sends: nested at most MAX_DEPTH deep, and parsed in valita’s strict mode even inside a lenient parse, so an AST with a key zero doesn’t know is rejected rather than run as a different query.

Constants§

MAX_DEPTH
MAX_AST_DEPTH.

Functions§

decode
exceeds_depth
exceedsASTDepth: every step down counts, except the one from an AST into its where clause.