Linux v69820.1blu.de 4.15.0 #1 SMP Mon Sep 30 15:36:27 MSK 2024 x86_64
Apache/2.4.58
Server IP : 195.90.215.149 & Your IP : 216.73.217.80
Domains :
Cant Read [ /etc/named.conf ]
User : www-data
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
usr /
share /
nodejs /
ajv /
lib /
vocabularies /
dynamic /
Delete
Unzip
Name
Size
Permission
Date
Action
dynamicAnchor.ts
1.1
KB
-rw-r--r--
2023-12-16 08:36
dynamicRef.ts
1.75
KB
-rw-r--r--
2023-12-16 08:36
index.ts
328
B
-rw-r--r--
2023-12-16 08:36
recursiveAnchor.ts
401
B
-rw-r--r--
2023-12-16 08:36
recursiveRef.ts
253
B
-rw-r--r--
2023-12-16 08:36
Save
Rename
import type {CodeKeywordDefinition} from "../../types" import type {KeywordCxt} from "../../compile/validate" import {_, getProperty, Code} from "../../compile/codegen" import N from "../../compile/names" import {SchemaEnv, compileSchema} from "../../compile" import {getValidate} from "../core/ref" const def: CodeKeywordDefinition = { keyword: "$dynamicAnchor", schemaType: "string", code: (cxt) => dynamicAnchor(cxt, cxt.schema), } export function dynamicAnchor(cxt: KeywordCxt, anchor: string): void { const {gen, it} = cxt it.schemaEnv.root.dynamicAnchors[anchor] = true const v = _`${N.dynamicAnchors}${getProperty(anchor)}` const validate = it.errSchemaPath === "#" ? it.validateName : _getValidate(cxt) gen.if(_`!${v}`, () => gen.assign(v, validate)) } function _getValidate(cxt: KeywordCxt): Code { const {schemaEnv, schema, self} = cxt.it const {root, baseId, localRefs, meta} = schemaEnv.root const {schemaId} = self.opts const sch = new SchemaEnv({schema, schemaId, root, baseId, localRefs, meta}) compileSchema.call(self, sch) return getValidate(cxt, sch) } export default def