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

21
node_modules/@graphql-tools/utils/esm/jsutils.js generated vendored Normal file
View File

@@ -0,0 +1,21 @@
export function isIterableObject(value) {
return value != null && typeof value === 'object' && Symbol.iterator in value;
}
export function isObjectLike(value) {
return typeof value === 'object' && value !== null;
}
export function isPromise(value) {
return isObjectLike(value) && typeof value['then'] === 'function';
}
export function promiseReduce(values, callbackFn, initialValue) {
let accumulator = initialValue;
for (const value of values) {
accumulator = isPromise(accumulator)
? accumulator.then(resolved => callbackFn(resolved, value))
: callbackFn(accumulator, value);
}
return accumulator;
}
export function hasOwnProperty(obj, prop) {
return Object.prototype.hasOwnProperty.call(obj, prop);
}