Sha256: 4a6aa220ee060de6a16dfe50feb0c213764ee1a23720f7297ece00b9c44e030a

Contents?: true

Size: 990 Bytes

Versions: 161

Compression:

Stored size: 990 Bytes

Contents

{"version":3,"names":["_validate","require","_index","validateNode","node","keys","BUILDER_KEYS","type","key","validate"],"sources":["../../src/builders/validateNode.ts"],"sourcesContent":["import validate from \"../validators/validate.ts\";\nimport type * as t from \"../index.ts\";\nimport { BUILDER_KEYS } from \"../index.ts\";\n\nexport default function validateNode<N extends t.Node>(node: N) {\n  // todo: because keys not in BUILDER_KEYS are not validated - this actually allows invalid nodes in some cases\n  const keys = BUILDER_KEYS[node.type] as (keyof N & string)[];\n  for (const key of keys) {\n    validate(node, key, node[key]);\n  }\n  return node;\n}\n"],"mappings":";;;;;;AAAA,IAAAA,SAAA,GAAAC,OAAA;AAEA,IAAAC,MAAA,GAAAD,OAAA;AAEe,SAASE,YAAYA,CAAmBC,IAAO,EAAE;EAE9D,MAAMC,IAAI,GAAGC,mBAAY,CAACF,IAAI,CAACG,IAAI,CAAyB;EAC5D,KAAK,MAAMC,GAAG,IAAIH,IAAI,EAAE;IACtB,IAAAI,iBAAQ,EAACL,IAAI,EAAEI,GAAG,EAAEJ,IAAI,CAACI,GAAG,CAAC,CAAC;EAChC;EACA,OAAOJ,IAAI;AACb","ignoreList":[]}

Version data entries

161 entries across 15 versions & 2 rubygems

Version Path
immosquare-cleaner-0.1.49 node_modules/@babel/helper-builder-binary-assignment-operator-visitor/node_modules/@babel/types/lib/builders/validateNode.js.map
immosquare-cleaner-0.1.49 node_modules/@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly/node_modules/@babel/traverse/node_modules/@babel/types/lib/builders/validateNode.js.map
immosquare-cleaner-0.1.49 node_modules/@babel/plugin-transform-async-generator-functions/node_modules/@babel/traverse/node_modules/@babel/types/lib/builders/validateNode.js.map
immosquare-cleaner-0.1.49 node_modules/@babel/helpers/node_modules/@babel/types/lib/builders/validateNode.js.map
immosquare-cleaner-0.1.49 node_modules/@babel/helper-split-export-declaration/node_modules/@babel/types/lib/builders/validateNode.js.map
immosquare-cleaner-0.1.49 node_modules/@babel/helper-wrap-function/node_modules/@babel/types/lib/builders/validateNode.js.map
immosquare-cleaner-0.1.49 node_modules/@babel/helper-environment-visitor/node_modules/@babel/types/lib/builders/validateNode.js.map
immosquare-cleaner-0.1.49 node_modules/@babel/plugin-transform-classes/node_modules/@babel/helper-replace-supers/node_modules/@babel/helper-member-expression-to-functions/node_modules/@babel/types/lib/builders/validateNode.js.map
immosquare-cleaner-0.1.49 node_modules/@babel/types/lib/builders/validateNode.js.map
immosquare-cleaner-0.1.49 node_modules/jscodeshift/node_modules/@babel/core/node_modules/@babel/types/lib/builders/validateNode.js.map
immosquare-cleaner-0.1.49 node_modules/@babel/helper-remap-async-to-generator/node_modules/@babel/traverse/node_modules/@babel/types/lib/builders/validateNode.js.map
immosquare-cleaner-0.1.49 node_modules/@babel/helper-simple-access/node_modules/@babel/types/lib/builders/validateNode.js.map
immosquare-cleaner-0.1.49 node_modules/@babel/preset-modules/node_modules/@babel/types/lib/builders/validateNode.js.map
immosquare-cleaner-0.1.49 node_modules/@babel/helper-optimise-call-expression/node_modules/@babel/types/lib/builders/validateNode.js.map
immosquare-cleaner-0.1.49 node_modules/@babel/plugin-transform-classes/node_modules/@babel/traverse/node_modules/@babel/types/lib/builders/validateNode.js.map
immosquare-cleaner-0.1.49 node_modules/@babel/plugin-transform-object-super/node_modules/@babel/helper-replace-supers/node_modules/@babel/traverse/node_modules/@babel/types/lib/builders/validateNode.js.map
immosquare-cleaner-0.1.49 node_modules/@babel/helper-function-name/node_modules/@babel/types/lib/builders/validateNode.js.map
immosquare-cleaner-0.1.49 node_modules/@babel/helper-module-imports/node_modules/@babel/types/lib/builders/validateNode.js.map
immosquare-cleaner-0.1.49 node_modules/@babel/helper-skip-transparent-expression-wrappers/node_modules/@babel/types/lib/builders/validateNode.js.map
immosquare-cleaner-0.1.49 node_modules/@babel/helper-annotate-as-pure/node_modules/@babel/types/lib/builders/validateNode.js.map