Initialisation

Added the packages and files for the backend server
This commit is contained in:
jackbeeby
2024-12-15 17:48:45 +11:00
parent 25066e1ee8
commit b412dfe2ca
2732 changed files with 330572 additions and 0 deletions

View File

@@ -0,0 +1,5 @@
import type { DocumentNode } from "graphql";
export declare function stripSensitiveLiterals(ast: DocumentNode, options?: {
hideListAndObjectLiterals?: boolean;
}): DocumentNode;
//# sourceMappingURL=index.d.ts.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAEV,YAAY,EAMb,MAAM,SAAS,CAAC;AAIjB,wBAAgB,sBAAsB,CACpC,GAAG,EAAE,YAAY,EACjB,OAAO,GAAE;IAAE,yBAAyB,CAAC,EAAE,OAAO,CAAA;CAE7C,GACA,YAAY,CAyBd"}

View File

@@ -0,0 +1,32 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.stripSensitiveLiterals = void 0;
const graphql_1 = require("graphql");
function stripSensitiveLiterals(ast, options = {
hideListAndObjectLiterals: false,
}) {
const listAndObjectVisitorIfEnabled = options.hideListAndObjectLiterals
? {
ListValue(node) {
return { ...node, values: [] };
},
ObjectValue(node) {
return { ...node, fields: [] };
},
}
: {};
return (0, graphql_1.visit)(ast, {
IntValue(node) {
return { ...node, value: "0" };
},
FloatValue(node) {
return { ...node, value: "0" };
},
StringValue(node) {
return { ...node, value: "", block: false };
},
...listAndObjectVisitorIfEnabled,
});
}
exports.stripSensitiveLiterals = stripSensitiveLiterals;
//# sourceMappingURL=index.js.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;AASA,qCAAgC;AAGhC,SAAgB,sBAAsB,CACpC,GAAiB,EACjB,UAAmD;IACjD,yBAAyB,EAAE,KAAK;CACjC;IAED,MAAM,6BAA6B,GACjC,OAAO,CAAC,yBAAyB;QAC/B,CAAC,CAAC;YACE,SAAS,CAAC,IAAmB;gBAC3B,OAAO,EAAE,GAAG,IAAI,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC;YACjC,CAAC;YACD,WAAW,CAAC,IAAqB;gBAC/B,OAAO,EAAE,GAAG,IAAI,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC;YACjC,CAAC;SACF;QACH,CAAC,CAAC,EAAE,CAAC;IAET,OAAO,IAAA,eAAK,EAAC,GAAG,EAAE;QAChB,QAAQ,CAAC,IAAI;YACX,OAAO,EAAE,GAAG,IAAI,EAAE,KAAK,EAAE,GAAG,EAAE,CAAC;QACjC,CAAC;QACD,UAAU,CAAC,IAAI;YACb,OAAO,EAAE,GAAG,IAAI,EAAE,KAAK,EAAE,GAAG,EAAE,CAAC;QACjC,CAAC;QACD,WAAW,CAAC,IAAI;YACd,OAAO,EAAE,GAAG,IAAI,EAAE,KAAK,EAAE,EAAE,EAAE,KAAK,EAAE,KAAK,EAAE,CAAC;QAC9C,CAAC;QACD,GAAG,6BAA6B;KACjC,CAAC,CAAC;AACL,CAAC;AA9BD,wDA8BC"}