diff --git a/.depcheckrc b/.depcheckrc index be7e6f7..214528c 100644 --- a/.depcheckrc +++ b/.depcheckrc @@ -14,5 +14,6 @@ ignores: [ "eslint-plugin-react-refresh", "glob", "dotenv", - "npm-run-all" + "npm-run-all", + "husky" ] diff --git a/.syncpackrc b/.syncpackrc index b8a19fb..72cfe45 100644 --- a/.syncpackrc +++ b/.syncpackrc @@ -13,7 +13,7 @@ "prod", "dev" ], - "pinVersion": "workspace:*" + "pinVersion": "^3.0.0" } ], "dependencyTypes": [ diff --git a/packages/starter-trpc/.depcheckrc b/packages/starter-trpc/.depcheckrc new file mode 100644 index 0000000..9dd2010 --- /dev/null +++ b/packages/starter-trpc/.depcheckrc @@ -0,0 +1,4 @@ +ignores: [ + "@types/node", + "vite" +] diff --git a/packages/starter-trpc/.editorconfig b/packages/starter-trpc/.editorconfig new file mode 100644 index 0000000..06570aa --- /dev/null +++ b/packages/starter-trpc/.editorconfig @@ -0,0 +1,11 @@ +root = true + +[*] +indent_style = space +indent_size = 4 +charset = utf-8 +trim_trailing_whitespace = true +insert_final_newline = true + +[*.{yaml,yml,json}] +indent_size = 2 diff --git a/packages/starter-trpc/.eslintignore b/packages/starter-trpc/.eslintignore new file mode 100644 index 0000000..d3a1239 --- /dev/null +++ b/packages/starter-trpc/.eslintignore @@ -0,0 +1 @@ +docs/* \ No newline at end of file diff --git a/packages/starter-trpc/.eslintrc.cjs b/packages/starter-trpc/.eslintrc.cjs new file mode 100644 index 0000000..2bb9eb7 --- /dev/null +++ b/packages/starter-trpc/.eslintrc.cjs @@ -0,0 +1,4 @@ +module.exports = { + root: true, + extends: ["@owlprotocol/eslint-config"], +}; diff --git a/packages/starter-trpc/.firebaserc b/packages/starter-trpc/.firebaserc new file mode 100644 index 0000000..9a0208d --- /dev/null +++ b/packages/starter-trpc/.firebaserc @@ -0,0 +1,10 @@ +{ + "projects": { + "default": "demo-owlprotocol", + "staging": "owl-protocol-staging", + "production": "owl-protocol" + }, + "targets": {}, + "etags": {}, + "dataconnectEmulatorConfig": {} +} diff --git a/packages/starter-trpc/.gitignore b/packages/starter-trpc/.gitignore new file mode 100644 index 0000000..cc9ea68 --- /dev/null +++ b/packages/starter-trpc/.gitignore @@ -0,0 +1,59 @@ +# See https://help.github.com/articles/ignoring-files/ for more about ignoring files. +.firebase + +cache/ + +# dependencies +node_modules +.pnp +.pnp.js + +# testing +coverage + +# build outputs +.next/ +out/ +build +.build +.esbuild +dist +dist-ssr +lib +.serverless + +# local deployments +packages/contracts/packages/owlprotocol-contracts/deployments/ganache/* + +# misc +.DS_Store +*.pem +.idea + +# debug +npm-debug.log* +yarn-debug.log* +yarn-error.log* +.pnpm-debug.log* +logs +*.log + +# local env files +.env.local +.env.development +.env.test +.env.production +.env + +# turbo +.turbo + +# local +*.local + +# ipfs +.ipfs +.datastore +.datastore_fs +.datastore_level +.datastore_s3 diff --git a/packages/starter-trpc/.lintstagedrc.json b/packages/starter-trpc/.lintstagedrc.json new file mode 100644 index 0000000..45defb5 --- /dev/null +++ b/packages/starter-trpc/.lintstagedrc.json @@ -0,0 +1,5 @@ +{ + "*.+(js|jsx)": ["eslint --fix", "git add"], + "*.+(ts|tsx)": ["eslint --fix", "git add"], + "*.+(json|css|md)": ["prettier --write", "git add"] +} diff --git a/packages/starter-trpc/.prettierrc.cjs b/packages/starter-trpc/.prettierrc.cjs new file mode 100644 index 0000000..4e0b563 --- /dev/null +++ b/packages/starter-trpc/.prettierrc.cjs @@ -0,0 +1,3 @@ +module.exports = { + ...require("@owlprotocol/prettier-config"), +}; diff --git a/packages/starter-trpc/LICENSE b/packages/starter-trpc/LICENSE new file mode 100644 index 0000000..16a5ecb --- /dev/null +++ b/packages/starter-trpc/LICENSE @@ -0,0 +1,7 @@ +Copyright 2024 Owl Protocol + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, libribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/packages/starter-trpc/README.md b/packages/starter-trpc/README.md new file mode 100644 index 0000000..c947f0e --- /dev/null +++ b/packages/starter-trpc/README.md @@ -0,0 +1,17 @@ +# TRPC Starter + +## Start + +Example requests + +```bash +npm run dev #Start server + +# Query Procedure +curl localhost:3000/api/hello #OpenAPI Call +curl localhost:3000/api/trpc/hello #TRPC Call + +# Mutation Procedure +curl localhost:3000/api/auth -d "" -H "x-api-key: test" #OpenAPI Call +curl localhost:3000/api/trpc/auth -d "" -H "Content-Type: application/json" -H "x-api-key: test" #TRPC Call +``` diff --git a/packages/starter-trpc/esbuild.config.mjs b/packages/starter-trpc/esbuild.config.mjs new file mode 100644 index 0000000..38551cc --- /dev/null +++ b/packages/starter-trpc/esbuild.config.mjs @@ -0,0 +1,9 @@ +import { buildLibESM, cjsBundleConfig, buildDistCJS } from "@owlprotocol/esbuild-config"; + +cjsBundleConfig.entryPoints = ["src/runtimes/firebase.ts"]; +cjsBundleConfig.outfile = "dist/index.js"; +cjsBundleConfig.plugins = []; +cjsBundleConfig.platform = "node"; +cjsBundleConfig.external = [...cjsBundleConfig.external, "firebase-admin", "firebase-functions"]; + +await Promise.all([buildLibESM(), buildDistCJS()]); diff --git a/packages/starter-trpc/firebase.json b/packages/starter-trpc/firebase.json new file mode 100644 index 0000000..9989d51 --- /dev/null +++ b/packages/starter-trpc/firebase.json @@ -0,0 +1,48 @@ +{ + "functions": [ + { + "source": "dist", + "codebase": "default", + "ignore": ["node_modules", ".git", "firebase-debug.log", "firebase-debug.*.log", "*.local"] + } + ], + "hosting": { + "public": "public", + "rewrites": [ + { + "source": "**", + "function": { + "functionId": "base", + "region": "europe-west3" + } + } + ] + }, + "emulators": { + "auth": { + "enabled": false, + "port": 9099 + }, + "firestore": { + "enabled": false, + "port": 18080 + }, + "storage": { + "enabled": false, + "port": 9199 + }, + "functions": { + "enabled": true, + "port": 5001 + }, + "hosting": { + "enabled": true, + "port": 5000 + }, + "ui": { + "enabled": true, + "port": 4000 + }, + "singleProjectMode": true + } +} diff --git a/packages/starter-trpc/package.firebase.json b/packages/starter-trpc/package.firebase.json new file mode 100644 index 0000000..e101d8d --- /dev/null +++ b/packages/starter-trpc/package.firebase.json @@ -0,0 +1,33 @@ +{ + "name": "@owlprotocol/starter-trpc", + "version": "0.0.0", + "keywords": ["firebase"], + "private": true, + "type": "commonjs", + "homepage": "https://github.com/owlprotocol/workspace-public", + "repository": { + "type": "git", + "url": "https://github.com/owlprotocol/workspace-public.git" + }, + "copyright": "Copyright 2024 Leo Vigna", + "license": "MIT", + "author": { + "name": "Leo Vigna", + "email": "leo@owlprotocol.xyz", + "url": "https://github.com/leovigna" + }, + "files": ["dist/*", "lib/*", "src/*", "LICENSE", "README.md"], + "main": "./index.js", + "dependencies": { + "firebase-admin": "^12.1.0", + "firebase-functions": "^5.0.0" + }, + "bugs": { + "url": "https://github.com/leovigna/owlprotocol/issues", + "email": "leo@owlprotocol.xyz" + }, + "funding": "https://github.com/leovigna/owlprotocol", + "engines": { + "node": "18" + } +} diff --git a/packages/starter-trpc/package.json b/packages/starter-trpc/package.json new file mode 100644 index 0000000..60916cc --- /dev/null +++ b/packages/starter-trpc/package.json @@ -0,0 +1,120 @@ +{ + "name": "@owlprotocol/starter-trpc", + "version": "3.0.0", + "keywords": [ + "web3", + "solidity", + "trpc", + "react-query" + ], + "private": true, + "type": "module", + "homepage": "https://github.com/owlprotocol/workspace-public", + "repository": { + "type": "git", + "url": "https://github.com/owlprotocol/workspace-public.git" + }, + "copyright": "Copyright 2024 Owl Protocol", + "license": "MIT", + "author": { + "name": "Leo Vigna", + "email": "leo@owlprotocol.xyz", + "url": "https://github.com/leovigna" + }, + "files": [ + "dist/*", + "lib/*", + "src/*", + "LICENSE", + "README.md" + ], + "main": "./lib/cjs/index.cjs", + "module": "./lib/esm/index.mjs", + "types": "./lib/types/index.d.ts", + "exports": { + ".": { + "types": "./lib/types/index.d.ts", + "require": "./lib/cjs/index.js", + "import": "./lib/esm/index.js" + }, + "./client": { + "types": "./lib/types/client/client.d.ts", + "require": "./lib/cjs/client/client.js", + "import": "./lib/esm/client/client.js" + }, + "./react-query": { + "types": "./lib/types/client/react.d.ts", + "require": "./lib/cjs/client/react.js", + "import": "./lib/esm/client/react.js" + } + }, + "scripts": { + "build": "npm-run-all -p tsc esbuild build:files", + "build:watch": "npm run build:files && npm-run-all -p tsc:watch esbuild:watch", + "build:files": "mkdir -p dist && cp package.firebase.json dist/package.json && cp .gitignore dist/", + "clean": "rimraf lib dist", + "depcheck": "depcheck", + "dev": "npm run dev:express", + "dev:express": "tsx watch src/runtimes/express.ts", + "dev:firebase": "npm-run-all -p build:watch firebase-emulator", + "deploy:firebase": "npm run build && firebase deploy --only functions,hosting", + "esbuild": "node esbuild.config.mjs", + "esbuild:watch": "ESBUILD_WATCH=true node esbuild.config.mjs", + "firebase-emulator": "firebase emulators:start --project demo-owlprotocol --debug", + "lint": "eslint 'src/**/*.ts'", + "lint:fix": "eslint --fix 'src/**/*.ts'", + "lint:staged": "lint-staged", + "madge": "madge src/index.ts -c", + "start": "node lib/esm/runtimes/express.js", + "test": "pnpm run test:ci", + "test:ci": "vitest --run", + "test:watch": "vitest", + "tsc": "tsc", + "tsc:trace": "tsc --generateTrace lib/trace && analyze-trace lib/trace", + "tsc:watch": "tsc -w" + }, + "dependencies": { + "@trpc/client": "11.0.0-next-beta.308", + "@trpc/server": "11.0.0-next-beta.308", + "firebase-admin": "^12.1.0", + "firebase-functions": "^5.0.0", + "express": "^4.18.2", + "trpc-openapi": "^1.2.0", + "zod": "3.22.4" + }, + "peerDependencies": { + "@tanstack/react-query": "5.24.8", + "@trpc/react-query": "11.0.0-next-beta.308", + "cross-fetch": "^4.0.0" + }, + "devDependencies": { + "@owlprotocol/esbuild-config": "^3.0.0", + "@owlprotocol/eslint-config": "^3.0.0", + "@owlprotocol/prettier-config": "^3.0.0", + "@owlprotocol/tsconfig": "^3.0.0", + "@tanstack/react-query": "5.24.8", + "@trpc/react-query": "11.0.0-next-beta.308", + "@types/express": "^4.17.16", + "@types/node": "^20.11.10", + "@typescript/analyze-trace": "^0.10.1", + "firebase-tools": "^13.16.0", + "lint-staged": "^11.2.6", + "madge": "^5.0.2", + "npm-run-all": "^4.1.5", + "rimraf": "^3.0.2", + "tsx": "^4.11.0", + "typescript": "5.4.5", + "vite": "^5.1.6", + "vitest": "^1.4.0", + "cross-fetch": "^4.0.0", + "depcheck": "^1.4.7" + }, + "bugs": { + "url": "https://github.com/owlprotocol/workspace-public/issues", + "email": "leo@owlprotocol.xyz" + }, + "funding": "https://owlprotocol.xyz", + "engines": { + "node": "^18.0.0" + } +} diff --git a/packages/starter-trpc/public/index.html b/packages/starter-trpc/public/index.html new file mode 100644 index 0000000..a7daaed --- /dev/null +++ b/packages/starter-trpc/public/index.html @@ -0,0 +1 @@ +Please go to /api/hello \ No newline at end of file diff --git a/packages/starter-trpc/src/client/client.ts b/packages/starter-trpc/src/client/client.ts new file mode 100644 index 0000000..f6e2e54 --- /dev/null +++ b/packages/starter-trpc/src/client/client.ts @@ -0,0 +1,44 @@ +import { HTTPHeaders, createTRPCProxyClient, httpBatchLink } from "@trpc/client"; +import fetch from "cross-fetch"; +import { AppRouter } from "../router.js"; + +/** + * Create JS TRPC Client + * @param apiKey + * @param url + * @returns + */ +export function createClient( + auth?: { + headers?: HTTPHeaders | (() => HTTPHeaders | Promise); + apiKey?: string; + jwt?: string; + }, + url = "http://localhost:3000/api/trpc", +): AppClient { + const headersDefault = () => { + if (auth?.apiKey) { + return { "x-api-key": auth.apiKey }; + } else if (auth?.jwt) { + return { authorization: auth.jwt }; + } else { + return {}; + } + }; + const headers = auth?.headers ?? headersDefault; + + const client = createTRPCProxyClient({ + links: [ + httpBatchLink({ + url, + fetch, + // You can pass any HTTP headers you wish here + headers, + }), + ], + }); + + return client; +} + +export type AppClient = ReturnType>; diff --git a/packages/starter-trpc/src/client/react.ts b/packages/starter-trpc/src/client/react.ts new file mode 100644 index 0000000..0fa4eb7 --- /dev/null +++ b/packages/starter-trpc/src/client/react.ts @@ -0,0 +1,50 @@ +import { createTRPCReact } from "@trpc/react-query"; +import { HTTPHeaders, httpBatchLink } from "@trpc/client"; +import { AppRouter } from "../router.js"; +export type { AppRouter }; +export * from "./client.js"; + +export type AppReactQuery = ReturnType>; +export const trpc: AppReactQuery = createTRPCReact(); + +/** + * Create React TRPC Client + * @param apiKey + * @param url + * @returns + */ +export function createClient( + headers?: HTTPHeaders | (() => HTTPHeaders | Promise), + url = "http://localhost:3000/api/trpc", +): ReturnType<(typeof trpc)["createClient"]> { + return trpc.createClient({ + links: [ + httpBatchLink({ + url, + headers, + }), + ], + }); +} + +//TODO: For SSR useState +/** + * Create React TRPC Client Hook + * @param url + * @returns + */ +export function useClient( + headers: () => Promise>, + url = "http://localhost:3000/api/trpc", +): [ReturnType<(typeof trpc)["createClient"]>] { + const trpcClient = trpc.createClient({ + links: [ + httpBatchLink({ + url, + headers, + }), + ], + }); + + return [trpcClient]; +} diff --git a/packages/starter-trpc/src/index.test.ts b/packages/starter-trpc/src/index.test.ts new file mode 100644 index 0000000..8ff047c --- /dev/null +++ b/packages/starter-trpc/src/index.test.ts @@ -0,0 +1,7 @@ +import { describe, test, expect } from "vitest"; + +describe("Dummy Test (so vitest works)", function () { + test("expect(true).toBe(true)", async () => { + expect(true).toBe(true); + }); +}); diff --git a/packages/starter-trpc/src/index.ts b/packages/starter-trpc/src/index.ts new file mode 100644 index 0000000..a639ee9 --- /dev/null +++ b/packages/starter-trpc/src/index.ts @@ -0,0 +1,2 @@ +export * from "./trpc.js"; +export * from "./router.js"; diff --git a/packages/starter-trpc/src/router.ts b/packages/starter-trpc/src/router.ts new file mode 100644 index 0000000..1960d3b --- /dev/null +++ b/packages/starter-trpc/src/router.ts @@ -0,0 +1,17 @@ +import { authProcedure, helloProcedure } from "./routes/index.js"; +import { t } from "./trpc.js"; +/** + * appRouter is the collection of routes that we make available + */ +export const appRouter = t.router({ + hello: helloProcedure, + auth: authProcedure, +}); + +export const createCaller = t.createCallerFactory(appRouter); + +/** + * AppRouter is the type of the above appRouter. We specify it to reduce the load on the linter + */ +export type AppRouter = typeof appRouter; +export type AppCaller = ReturnType; diff --git a/packages/starter-trpc/src/routes/auth.ts b/packages/starter-trpc/src/routes/auth.ts new file mode 100644 index 0000000..f554b15 --- /dev/null +++ b/packages/starter-trpc/src/routes/auth.ts @@ -0,0 +1,34 @@ +import { z } from "zod"; +import { TRPCError } from "@trpc/server"; +import { t } from "../trpc.js"; + +/** + * @param name + * @returns Hello World message + */ +export const authProcedure = t.procedure + .meta({ + openapi: { + method: "POST" as const, + path: "/auth" as const, + protect: true, + description: "Authenticate with api key in header", + summary: "Authenticate", + tags: ["Auth"], + }, + }) + .input(z.void()) + .output(z.string()) + .mutation(({ ctx }) => { + const { req } = ctx; + const reqHeaders = req.headers; + const apiKey = reqHeaders["x-api-key"] as string | undefined; + + console.debug({ apiKey }); + + if (!apiKey) { + throw new TRPCError({ message: "No API Key", code: "UNAUTHORIZED" }); + } + + return "ok"; + }); diff --git a/packages/starter-trpc/src/routes/hello.ts b/packages/starter-trpc/src/routes/hello.ts new file mode 100644 index 0000000..aa20d1f --- /dev/null +++ b/packages/starter-trpc/src/routes/hello.ts @@ -0,0 +1,35 @@ +import { z } from "zod"; +import { t } from "../trpc.js"; + +/** + * @param name + * @returns Hello World message + */ +export const helloProcedure = t.procedure + .meta({ + openapi: { + method: "GET" as const, + path: "/hello" as const, + protect: true, + description: "Hello world demo. Add optional input message", + summary: "Hello", + tags: ["API"], + example: { + request: { + message: "Good morning!", + }, + response: { + message: "Hello World!\nEcho: Good morning!", + }, + }, + }, + }) + .input(z.object({ message: z.string().optional() }).optional()) + .output(z.object({ message: z.string() })) + .query(({ input }) => { + console.debug({ input }); + return { + //Return hello world + echo message if given + message: `Hello World!\nEcho: ${input?.message ?? "No message"}`, + }; + }); diff --git a/packages/starter-trpc/src/routes/index.ts b/packages/starter-trpc/src/routes/index.ts new file mode 100644 index 0000000..427f9f4 --- /dev/null +++ b/packages/starter-trpc/src/routes/index.ts @@ -0,0 +1,2 @@ +export * from "./auth.js"; +export * from "./hello.js"; diff --git a/packages/starter-trpc/src/runtimes/app.ts b/packages/starter-trpc/src/runtimes/app.ts new file mode 100644 index 0000000..b4f1b02 --- /dev/null +++ b/packages/starter-trpc/src/runtimes/app.ts @@ -0,0 +1,15 @@ +import { createExpressMiddleware } from "@trpc/server/adapters/express"; +import express, { Express } from "express"; +import { createOpenApiExpressMiddleware } from "trpc-openapi"; +import { appRouter } from "../router.js"; +import { createContext } from "../trpc.js"; + +export const app = express() as Express; + +// Handle incoming tRPC requests +app.use("/api/trpc", createExpressMiddleware({ router: appRouter, createContext })); + +// Handle incoming OpenAPI requests +//TODO: Why the type error now after refactor? +//@ts-expect-error +app.use("/api", createOpenApiExpressMiddleware({ router: appRouter, createContext })); diff --git a/packages/starter-trpc/src/runtimes/express.ts b/packages/starter-trpc/src/runtimes/express.ts new file mode 100644 index 0000000..b2305ca --- /dev/null +++ b/packages/starter-trpc/src/runtimes/express.ts @@ -0,0 +1,9 @@ +import { app } from "./app.js"; + +export function runExpress() { + app.listen(3000, () => { + console.log(`Server started on http://localhost:3000`); + }); +} + +runExpress(); diff --git a/packages/starter-trpc/src/runtimes/firebase.ts b/packages/starter-trpc/src/runtimes/firebase.ts new file mode 100644 index 0000000..48a5c0b --- /dev/null +++ b/packages/starter-trpc/src/runtimes/firebase.ts @@ -0,0 +1,26 @@ +/** + * Import function triggers from their respective submodules: + * + * import {onCall} from "firebase-functions/v2/https"; + * import {onDocumentWritten} from "firebase-functions/v2/firestore"; + * + * See a full list of supported triggers at https://firebase.google.com/docs/functions + */ + +import { onRequest } from "firebase-functions/v2/https"; +import { app } from "./app.js"; + +// Start writing functions +// https://firebase.google.com/docs/functions/typescript +export const base = onRequest( + { + region: "europe-west3", + concurrency: 80, + cpu: 1, + minInstances: 1, + maxInstances: 1, + timeoutSeconds: 60 * 5, + memory: "2GiB", + }, + app, +); diff --git a/packages/starter-trpc/src/trpc.ts b/packages/starter-trpc/src/trpc.ts new file mode 100644 index 0000000..8209465 --- /dev/null +++ b/packages/starter-trpc/src/trpc.ts @@ -0,0 +1,46 @@ +import { initTRPC } from "@trpc/server"; +import { CreateExpressContextOptions } from "@trpc/server/adapters/express"; +import { OpenApiMeta } from "trpc-openapi"; + +/** + * Overridable TRPC Context. + * Context can be extended beyond this interface using middleware. + */ +export type Context = { + /***** Express Req/Response*****/ + readonly req: { + body: Record; + headers: Record; + [k: string]: any; + }; + readonly res?: CreateExpressContextOptions["res"]; + + /** Project apiKey. Used for authenticating as service account */ + readonly apiKey?: string; +}; + +//TODO: What does this do? +export const t = initTRPC + .context() + .meta() + .create({ + errorFormatter: ({ error, shape }) => { + console.debug(error); + if (error.code === "INTERNAL_SERVER_ERROR" && process.env.NODE_ENV === "production") { + return { ...shape, message: "Internal server error" }; + } + return shape; + }, + }); + +/** + * createContext creates the initial context. Middlewares can add to this context + * NOTE: This is only called in the express server when a request is made. + * When testing you need to create to create a context and pass it to a procedure call + */ +export const createContext = async ({ req, res }: CreateExpressContextOptions): Promise => { + return { + req, + res, + } as Context; +}; diff --git a/packages/starter-trpc/src/types/environment.d.ts b/packages/starter-trpc/src/types/environment.d.ts new file mode 100644 index 0000000..8f5e5ee --- /dev/null +++ b/packages/starter-trpc/src/types/environment.d.ts @@ -0,0 +1,12 @@ +declare global { + namespace NodeJS { + interface ProcessEnv { + NAME?: string; + NODE_ENV: "development" | "production" | "test"; + } + } +} + +// If this file has no import/export statements (i.e. is a script) +// convert it into a module by adding an empty export statement. +export {}; diff --git a/packages/starter-trpc/src/types/modules.d.ts b/packages/starter-trpc/src/types/modules.d.ts new file mode 100644 index 0000000..f44912c --- /dev/null +++ b/packages/starter-trpc/src/types/modules.d.ts @@ -0,0 +1 @@ +//Declare packages that don't come with types here diff --git a/packages/starter-trpc/tsconfig.json b/packages/starter-trpc/tsconfig.json new file mode 100644 index 0000000..b1ae0db --- /dev/null +++ b/packages/starter-trpc/tsconfig.json @@ -0,0 +1,7 @@ +{ + "compilerOptions": { + "outDir": "lib/types" + }, + "include": ["src"], + "extends": "@owlprotocol/tsconfig" +} diff --git a/packages/starter-trpc/vite.config.ts b/packages/starter-trpc/vite.config.ts new file mode 100644 index 0000000..3bef263 --- /dev/null +++ b/packages/starter-trpc/vite.config.ts @@ -0,0 +1,16 @@ +/// +import { defineConfig } from "vite"; + +export default defineConfig({ + plugins: [], + test: { + //environment: "jsdom", + globals: false, + globalSetup: "vitest.setup.ts", + testTimeout: 60000, + threads: false, + watch: true, + include: ["src/**/*.test.ts"], + //setupFiles: "./src/test/setup.ts", + }, +}); diff --git a/packages/starter-trpc/vitest.setup.ts b/packages/starter-trpc/vitest.setup.ts new file mode 100644 index 0000000..d5d53c4 --- /dev/null +++ b/packages/starter-trpc/vitest.setup.ts @@ -0,0 +1,11 @@ +/** + * Run once on `vitest` command. NOT on test re-runs + */ +// eslint-disable-next-line @typescript-eslint/no-empty-function +export function setup() {} + +/** + * Run once `vitest` process has exited. NOT on test re-runs + */ +// eslint-disable-next-line @typescript-eslint/no-empty-function +export function teardown() {} diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 5ce0211..b7a680c 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -200,6 +200,91 @@ importers: specifier: ^1.4.0 version: 1.6.0(@types/node@20.16.5) + packages/starter-trpc: + dependencies: + '@trpc/client': + specifier: 11.0.0-next-beta.308 + version: 11.0.0-next-beta.308(@trpc/server@11.0.0-next-beta.308) + '@trpc/server': + specifier: 11.0.0-next-beta.308 + version: 11.0.0-next-beta.308 + express: + specifier: ^4.18.2 + version: 4.21.1 + firebase-admin: + specifier: ^12.1.0 + version: 12.7.0(encoding@0.1.13) + firebase-functions: + specifier: ^5.0.0 + version: 5.1.1(firebase-admin@12.7.0(encoding@0.1.13)) + trpc-openapi: + specifier: ^1.2.0 + version: 1.2.0(@trpc/server@11.0.0-next-beta.308)(@types/express@4.17.21)(@types/node@20.16.5)(zod@3.22.4) + zod: + specifier: 3.22.4 + version: 3.22.4 + devDependencies: + '@owlprotocol/esbuild-config': + specifier: ^3.0.0 + version: 3.1.0 + '@owlprotocol/eslint-config': + specifier: ^3.0.0 + version: 3.1.0 + '@owlprotocol/prettier-config': + specifier: ^3.0.0 + version: 3.1.0 + '@owlprotocol/tsconfig': + specifier: ^3.0.0 + version: 3.1.0 + '@tanstack/react-query': + specifier: 5.24.8 + version: 5.24.8(react@18.3.1) + '@trpc/react-query': + specifier: 11.0.0-next-beta.308 + version: 11.0.0-next-beta.308(@tanstack/react-query@5.24.8(react@18.3.1))(@trpc/client@11.0.0-next-beta.308(@trpc/server@11.0.0-next-beta.308))(@trpc/server@11.0.0-next-beta.308) + '@types/express': + specifier: ^4.17.16 + version: 4.17.21 + '@types/node': + specifier: ^20.11.10 + version: 20.16.5 + '@typescript/analyze-trace': + specifier: ^0.10.1 + version: 0.10.1 + cross-fetch: + specifier: ^4.0.0 + version: 4.0.0(encoding@0.1.13) + depcheck: + specifier: ^1.4.7 + version: 1.4.7 + firebase-tools: + specifier: ^13.16.0 + version: 13.27.0(encoding@0.1.13) + lint-staged: + specifier: ^11.2.6 + version: 11.2.6 + madge: + specifier: ^5.0.2 + version: 5.0.2 + npm-run-all: + specifier: ^4.1.5 + version: 4.1.5 + rimraf: + specifier: ^3.0.2 + version: 3.0.2 + tsx: + specifier: ^4.11.0 + version: 4.19.2 + typescript: + specifier: 5.4.5 + version: 5.4.5 + vite: + specifier: ^5.1.6 + version: 5.4.7(@types/node@20.16.5) + vitest: + specifier: ^1.4.0 + version: 1.6.0(@types/node@20.16.5) + packages/starter-typescript: devDependencies: '@owlprotocol/esbuild-config': @@ -386,6 +471,12 @@ packages: cpu: [ppc64] os: [aix] + '@esbuild/aix-ppc64@0.23.1': + resolution: {integrity: sha512-6VhYk1diRqrhBAqpJEdjASR/+WVRtfjpqKuNw11cLiaWpAT/Uu+nokB+UJnevzy/P9C/ty6AOe0dwueMrGh/iQ==} + engines: {node: '>=18'} + cpu: [ppc64] + os: [aix] + '@esbuild/android-arm64@0.19.12': resolution: {integrity: sha512-P0UVNGIienjZv3f5zq0DP3Nt2IE/3plFzuaS96vihvD0Hd6H/q4WXUGpCxD/E8YrSXfNyRPbpTq+T8ZQioSuPA==} engines: {node: '>=12'} @@ -398,6 +489,12 @@ packages: cpu: [arm64] os: [android] + '@esbuild/android-arm64@0.23.1': + resolution: {integrity: sha512-xw50ipykXcLstLeWH7WRdQuysJqejuAGPd30vd1i5zSyKK3WE+ijzHmLKxdiCMtH1pHz78rOg0BKSYOSB/2Khw==} + engines: {node: '>=18'} + cpu: [arm64] + os: [android] + '@esbuild/android-arm@0.19.12': resolution: {integrity: sha512-qg/Lj1mu3CdQlDEEiWrlC4eaPZ1KztwGJ9B6J+/6G+/4ewxJg7gqj8eVYWvao1bXrqGiW2rsBZFSX3q2lcW05w==} engines: {node: '>=12'} @@ -410,6 +507,12 @@ packages: cpu: [arm] os: [android] + '@esbuild/android-arm@0.23.1': + resolution: {integrity: sha512-uz6/tEy2IFm9RYOyvKl88zdzZfwEfKZmnX9Cj1BHjeSGNuGLuMD1kR8y5bteYmwqKm1tj8m4cb/aKEorr6fHWQ==} + engines: {node: '>=18'} + cpu: [arm] + os: [android] + '@esbuild/android-x64@0.19.12': resolution: {integrity: sha512-3k7ZoUW6Q6YqhdhIaq/WZ7HwBpnFBlW905Fa4s4qWJyiNOgT1dOqDiVAQFwBH7gBRZr17gLrlFCRzF6jFh7Kew==} engines: {node: '>=12'} @@ -422,6 +525,12 @@ packages: cpu: [x64] os: [android] + '@esbuild/android-x64@0.23.1': + resolution: {integrity: sha512-nlN9B69St9BwUoB+jkyU090bru8L0NA3yFvAd7k8dNsVH8bi9a8cUAUSEcEEgTp2z3dbEDGJGfP6VUnkQnlReg==} + engines: {node: '>=18'} + cpu: [x64] + os: [android] + '@esbuild/darwin-arm64@0.19.12': resolution: {integrity: sha512-B6IeSgZgtEzGC42jsI+YYu9Z3HKRxp8ZT3cqhvliEHovq8HSX2YX8lNocDn79gCKJXOSaEot9MVYky7AKjCs8g==} engines: {node: '>=12'} @@ -434,6 +543,12 @@ packages: cpu: [arm64] os: [darwin] + '@esbuild/darwin-arm64@0.23.1': + resolution: {integrity: sha512-YsS2e3Wtgnw7Wq53XXBLcV6JhRsEq8hkfg91ESVadIrzr9wO6jJDMZnCQbHm1Guc5t/CdDiFSSfWP58FNuvT3Q==} + engines: {node: '>=18'} + cpu: [arm64] + os: [darwin] + '@esbuild/darwin-x64@0.19.12': resolution: {integrity: sha512-hKoVkKzFiToTgn+41qGhsUJXFlIjxI/jSYeZf3ugemDYZldIXIxhvwN6erJGlX4t5h417iFuheZ7l+YVn05N3A==} engines: {node: '>=12'} @@ -446,6 +561,12 @@ packages: cpu: [x64] os: [darwin] + '@esbuild/darwin-x64@0.23.1': + resolution: {integrity: sha512-aClqdgTDVPSEGgoCS8QDG37Gu8yc9lTHNAQlsztQ6ENetKEO//b8y31MMu2ZaPbn4kVsIABzVLXYLhCGekGDqw==} + engines: {node: '>=18'} + cpu: [x64] + os: [darwin] + '@esbuild/freebsd-arm64@0.19.12': resolution: {integrity: sha512-4aRvFIXmwAcDBw9AueDQ2YnGmz5L6obe5kmPT8Vd+/+x/JMVKCgdcRwH6APrbpNXsPz+K653Qg8HB/oXvXVukA==} engines: {node: '>=12'} @@ -458,6 +579,12 @@ packages: cpu: [arm64] os: [freebsd] + '@esbuild/freebsd-arm64@0.23.1': + resolution: {integrity: sha512-h1k6yS8/pN/NHlMl5+v4XPfikhJulk4G+tKGFIOwURBSFzE8bixw1ebjluLOjfwtLqY0kewfjLSrO6tN2MgIhA==} + engines: {node: '>=18'} + cpu: [arm64] + os: [freebsd] + '@esbuild/freebsd-x64@0.19.12': resolution: {integrity: sha512-EYoXZ4d8xtBoVN7CEwWY2IN4ho76xjYXqSXMNccFSx2lgqOG/1TBPW0yPx1bJZk94qu3tX0fycJeeQsKovA8gg==} engines: {node: '>=12'} @@ -470,6 +597,12 @@ packages: cpu: [x64] os: [freebsd] + '@esbuild/freebsd-x64@0.23.1': + resolution: {integrity: sha512-lK1eJeyk1ZX8UklqFd/3A60UuZ/6UVfGT2LuGo3Wp4/z7eRTRYY+0xOu2kpClP+vMTi9wKOfXi2vjUpO1Ro76g==} + engines: {node: '>=18'} + cpu: [x64] + os: [freebsd] + '@esbuild/linux-arm64@0.19.12': resolution: {integrity: sha512-EoTjyYyLuVPfdPLsGVVVC8a0p1BFFvtpQDB/YLEhaXyf/5bczaGeN15QkR+O4S5LeJ92Tqotve7i1jn35qwvdA==} engines: {node: '>=12'} @@ -482,6 +615,12 @@ packages: cpu: [arm64] os: [linux] + '@esbuild/linux-arm64@0.23.1': + resolution: {integrity: sha512-/93bf2yxencYDnItMYV/v116zff6UyTjo4EtEQjUBeGiVpMmffDNUyD9UN2zV+V3LRV3/on4xdZ26NKzn6754g==} + engines: {node: '>=18'} + cpu: [arm64] + os: [linux] + '@esbuild/linux-arm@0.19.12': resolution: {integrity: sha512-J5jPms//KhSNv+LO1S1TX1UWp1ucM6N6XuL6ITdKWElCu8wXP72l9MM0zDTzzeikVyqFE6U8YAV9/tFyj0ti+w==} engines: {node: '>=12'} @@ -494,6 +633,12 @@ packages: cpu: [arm] os: [linux] + '@esbuild/linux-arm@0.23.1': + resolution: {integrity: sha512-CXXkzgn+dXAPs3WBwE+Kvnrf4WECwBdfjfeYHpMeVxWE0EceB6vhWGShs6wi0IYEqMSIzdOF1XjQ/Mkm5d7ZdQ==} + engines: {node: '>=18'} + cpu: [arm] + os: [linux] + '@esbuild/linux-ia32@0.19.12': resolution: {integrity: sha512-Thsa42rrP1+UIGaWz47uydHSBOgTUnwBwNq59khgIwktK6x60Hivfbux9iNR0eHCHzOLjLMLfUMLCypBkZXMHA==} engines: {node: '>=12'} @@ -506,6 +651,12 @@ packages: cpu: [ia32] os: [linux] + '@esbuild/linux-ia32@0.23.1': + resolution: {integrity: sha512-VTN4EuOHwXEkXzX5nTvVY4s7E/Krz7COC8xkftbbKRYAl96vPiUssGkeMELQMOnLOJ8k3BY1+ZY52tttZnHcXQ==} + engines: {node: '>=18'} + cpu: [ia32] + os: [linux] + '@esbuild/linux-loong64@0.19.12': resolution: {integrity: sha512-LiXdXA0s3IqRRjm6rV6XaWATScKAXjI4R4LoDlvO7+yQqFdlr1Bax62sRwkVvRIrwXxvtYEHHI4dm50jAXkuAA==} engines: {node: '>=12'} @@ -518,6 +669,12 @@ packages: cpu: [loong64] os: [linux] + '@esbuild/linux-loong64@0.23.1': + resolution: {integrity: sha512-Vx09LzEoBa5zDnieH8LSMRToj7ir/Jeq0Gu6qJ/1GcBq9GkfoEAoXvLiW1U9J1qE/Y/Oyaq33w5p2ZWrNNHNEw==} + engines: {node: '>=18'} + cpu: [loong64] + os: [linux] + '@esbuild/linux-mips64el@0.19.12': resolution: {integrity: sha512-fEnAuj5VGTanfJ07ff0gOA6IPsvrVHLVb6Lyd1g2/ed67oU1eFzL0r9WL7ZzscD+/N6i3dWumGE1Un4f7Amf+w==} engines: {node: '>=12'} @@ -530,6 +687,12 @@ packages: cpu: [mips64el] os: [linux] + '@esbuild/linux-mips64el@0.23.1': + resolution: {integrity: sha512-nrFzzMQ7W4WRLNUOU5dlWAqa6yVeI0P78WKGUo7lg2HShq/yx+UYkeNSE0SSfSure0SqgnsxPvmAUu/vu0E+3Q==} + engines: {node: '>=18'} + cpu: [mips64el] + os: [linux] + '@esbuild/linux-ppc64@0.19.12': resolution: {integrity: sha512-nYJA2/QPimDQOh1rKWedNOe3Gfc8PabU7HT3iXWtNUbRzXS9+vgB0Fjaqr//XNbd82mCxHzik2qotuI89cfixg==} engines: {node: '>=12'} @@ -542,6 +705,12 @@ packages: cpu: [ppc64] os: [linux] + '@esbuild/linux-ppc64@0.23.1': + resolution: {integrity: sha512-dKN8fgVqd0vUIjxuJI6P/9SSSe/mB9rvA98CSH2sJnlZ/OCZWO1DJvxj8jvKTfYUdGfcq2dDxoKaC6bHuTlgcw==} + engines: {node: '>=18'} + cpu: [ppc64] + os: [linux] + '@esbuild/linux-riscv64@0.19.12': resolution: {integrity: sha512-2MueBrlPQCw5dVJJpQdUYgeqIzDQgw3QtiAHUC4RBz9FXPrskyyU3VI1hw7C0BSKB9OduwSJ79FTCqtGMWqJHg==} engines: {node: '>=12'} @@ -554,6 +723,12 @@ packages: cpu: [riscv64] os: [linux] + '@esbuild/linux-riscv64@0.23.1': + resolution: {integrity: sha512-5AV4Pzp80fhHL83JM6LoA6pTQVWgB1HovMBsLQ9OZWLDqVY8MVobBXNSmAJi//Csh6tcY7e7Lny2Hg1tElMjIA==} + engines: {node: '>=18'} + cpu: [riscv64] + os: [linux] + '@esbuild/linux-s390x@0.19.12': resolution: {integrity: sha512-+Pil1Nv3Umes4m3AZKqA2anfhJiVmNCYkPchwFJNEJN5QxmTs1uzyy4TvmDrCRNT2ApwSari7ZIgrPeUx4UZDg==} engines: {node: '>=12'} @@ -566,6 +741,12 @@ packages: cpu: [s390x] os: [linux] + '@esbuild/linux-s390x@0.23.1': + resolution: {integrity: sha512-9ygs73tuFCe6f6m/Tb+9LtYxWR4c9yg7zjt2cYkjDbDpV/xVn+68cQxMXCjUpYwEkze2RcU/rMnfIXNRFmSoDw==} + engines: {node: '>=18'} + cpu: [s390x] + os: [linux] + '@esbuild/linux-x64@0.19.12': resolution: {integrity: sha512-B71g1QpxfwBvNrfyJdVDexenDIt1CiDN1TIXLbhOw0KhJzE78KIFGX6OJ9MrtC0oOqMWf+0xop4qEU8JrJTwCg==} engines: {node: '>=12'} @@ -578,6 +759,12 @@ packages: cpu: [x64] os: [linux] + '@esbuild/linux-x64@0.23.1': + resolution: {integrity: sha512-EV6+ovTsEXCPAp58g2dD68LxoP/wK5pRvgy0J/HxPGB009omFPv3Yet0HiaqvrIrgPTBuC6wCH1LTOY91EO5hQ==} + engines: {node: '>=18'} + cpu: [x64] + os: [linux] + '@esbuild/netbsd-x64@0.19.12': resolution: {integrity: sha512-3ltjQ7n1owJgFbuC61Oj++XhtzmymoCihNFgT84UAmJnxJfm4sYCiSLTXZtE00VWYpPMYc+ZQmB6xbSdVh0JWA==} engines: {node: '>=12'} @@ -590,6 +777,18 @@ packages: cpu: [x64] os: [netbsd] + '@esbuild/netbsd-x64@0.23.1': + resolution: {integrity: sha512-aevEkCNu7KlPRpYLjwmdcuNz6bDFiE7Z8XC4CPqExjTvrHugh28QzUXVOZtiYghciKUacNktqxdpymplil1beA==} + engines: {node: '>=18'} + cpu: [x64] + os: [netbsd] + + '@esbuild/openbsd-arm64@0.23.1': + resolution: {integrity: sha512-3x37szhLexNA4bXhLrCC/LImN/YtWis6WXr1VESlfVtVeoFJBRINPJ3f0a/6LV8zpikqoUg4hyXw0sFBt5Cr+Q==} + engines: {node: '>=18'} + cpu: [arm64] + os: [openbsd] + '@esbuild/openbsd-x64@0.19.12': resolution: {integrity: sha512-RbrfTB9SWsr0kWmb9srfF+L933uMDdu9BIzdA7os2t0TXhCRjrQyCeOt6wVxr79CKD4c+p+YhCj31HBkYcXebw==} engines: {node: '>=12'} @@ -602,6 +801,12 @@ packages: cpu: [x64] os: [openbsd] + '@esbuild/openbsd-x64@0.23.1': + resolution: {integrity: sha512-aY2gMmKmPhxfU+0EdnN+XNtGbjfQgwZj43k8G3fyrDM/UdZww6xrWxmDkuz2eCZchqVeABjV5BpildOrUbBTqA==} + engines: {node: '>=18'} + cpu: [x64] + os: [openbsd] + '@esbuild/sunos-x64@0.19.12': resolution: {integrity: sha512-HKjJwRrW8uWtCQnQOz9qcU3mUZhTUQvi56Q8DPTLLB+DawoiQdjsYq+j+D3s9I8VFtDr+F9CjgXKKC4ss89IeA==} engines: {node: '>=12'} @@ -614,6 +819,12 @@ packages: cpu: [x64] os: [sunos] + '@esbuild/sunos-x64@0.23.1': + resolution: {integrity: sha512-RBRT2gqEl0IKQABT4XTj78tpk9v7ehp+mazn2HbUeZl1YMdaGAQqhapjGTCe7uw7y0frDi4gS0uHzhvpFuI1sA==} + engines: {node: '>=18'} + cpu: [x64] + os: [sunos] + '@esbuild/win32-arm64@0.19.12': resolution: {integrity: sha512-URgtR1dJnmGvX864pn1B2YUYNzjmXkuJOIqG2HdU62MVS4EHpU2946OZoTMnRUHklGtJdJZ33QfzdjGACXhn1A==} engines: {node: '>=12'} @@ -626,6 +837,12 @@ packages: cpu: [arm64] os: [win32] + '@esbuild/win32-arm64@0.23.1': + resolution: {integrity: sha512-4O+gPR5rEBe2FpKOVyiJ7wNDPA8nGzDuJ6gN4okSA1gEOYZ67N8JPk58tkWtdtPeLz7lBnY6I5L3jdsr3S+A6A==} + engines: {node: '>=18'} + cpu: [arm64] + os: [win32] + '@esbuild/win32-ia32@0.19.12': resolution: {integrity: sha512-+ZOE6pUkMOJfmxmBZElNOx72NKpIa/HFOMGzu8fqzQJ5kgf6aTGrcJaFsNiVMH4JKpMipyK+7k0n2UXN7a8YKQ==} engines: {node: '>=12'} @@ -638,6 +855,12 @@ packages: cpu: [ia32] os: [win32] + '@esbuild/win32-ia32@0.23.1': + resolution: {integrity: sha512-BcaL0Vn6QwCwre3Y717nVHZbAa4UBEigzFm6VdsVdT/MbZ38xoj1X9HPkZhbmaBGUD1W8vxAfffbDe8bA6AKnQ==} + engines: {node: '>=18'} + cpu: [ia32] + os: [win32] + '@esbuild/win32-x64@0.19.12': resolution: {integrity: sha512-T1QyPSDCyMXaO3pzBkF96E8xMkiRYbUEZADd29SyPGabqxMViNoii+NcK7eWJAEoU6RZyEm5lVSIjTmcdoB9HA==} engines: {node: '>=12'} @@ -650,6 +873,12 @@ packages: cpu: [x64] os: [win32] + '@esbuild/win32-x64@0.23.1': + resolution: {integrity: sha512-BHpFFeslkWrXWyUPnbKm+xYYVYruCinGcftSBaa8zoF9hZO4BcSCFUvHVTtzpIY6YzUnYtuEhZ+C9iEXjxnasg==} + engines: {node: '>=18'} + cpu: [x64] + os: [win32] + '@eslint-community/eslint-utils@4.4.1': resolution: {integrity: sha512-s3O3waFUrMV8P/XaF/+ZTp1X9XBZW1a4B97ZnjQF2KYWaFD2A8KyFBsrsfSjEmjn3RGWAIuvlneuZm3CUK3jbA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} @@ -914,6 +1143,9 @@ packages: engines: {node: '>=6'} hasBin: true + '@hapi/bourne@3.0.0': + resolution: {integrity: sha512-Waj1cwPXJDucOib4a3bAISsKJVb15MKi9IvmTI/7ssVEm6sywXGjVJDhl6/umt1pK1ZS7PacXU3A1PmFKHEZ2w==} + '@humanwhocodes/config-array@0.13.0': resolution: {integrity: sha512-DZLEEqFWQFiyK6h5YIeynKx7JlvCYWL0cImfSRXZ9l4Sg2efkFGTuFf6vzXjK1cq6IYkU+Eg/JizXw+TD2vRNw==} engines: {node: '>=10.10.0'} @@ -1217,6 +1449,21 @@ packages: '@tootallnate/quickjs-emscripten@0.23.0': resolution: {integrity: sha512-C5Mc6rdnsaJDjO3UpGW/CQTHtCKaYlScZTly4JIu97Jxo/odCiH0ITnDXSJPTOrEKk/ycSZ0AOgTmkDtkOsvIA==} + '@trpc/client@11.0.0-next-beta.308': + resolution: {integrity: sha512-bg8EV6qVZZl6/v9HhfmntEbPcjtzi3MFhdHUv9l24HLkLAJPvBCMMsjjFZG6PX+jwyXTFjSBGzaXwpnNtdE1tQ==} + peerDependencies: + '@trpc/server': 11.0.0-next-beta.308+955edd79a + + '@trpc/react-query@11.0.0-next-beta.308': + resolution: {integrity: sha512-+0g42nW0zOXfpRN90aMuhPZ/BvwQu4IOiWP5xByRq2E+EWrWxJAFdxgS4xpKR49KlM+vKLSgkqj5yeYXyd82hw==} + peerDependencies: + '@tanstack/react-query': ^5.0.0 + '@trpc/client': 11.0.0-next-beta.308+955edd79a + '@trpc/server': 11.0.0-next-beta.308+955edd79a + + '@trpc/server@11.0.0-next-beta.308': + resolution: {integrity: sha512-GdYgcbecAafHQszqMVeHrX45c0hhAISvB+w9Ja40nZcb4kgaNvhflSVIn8XbHKUG8urmYI9kTL2k8hD/59/LMA==} + '@tsconfig/node10@1.0.11': resolution: {integrity: sha512-DcRjDCujK/kCk/cUe8Xz8ZSpm8mS3mNNpta+jGCA6USEDfktlNvm1+IuZ9eTcDbNk41BHwpHHeW+N1lKCz4zOw==} @@ -1873,6 +2120,10 @@ packages: resolution: {integrity: sha512-JQHZ2QMW6l3aH/j6xCqQThY/9OH4D/9ls34cgkUBiEeocRTU04tHfKPBsUK1PqZCUQM7GiA0IIXJSuXHI64Kbg==} engines: {node: '>=0.8'} + co-body@6.2.0: + resolution: {integrity: sha512-Kbpv2Yd1NdL1V/V4cwLVxraHDV6K8ayohr2rmH0J87Er8+zJjcTa6dAn9QMPC9CRgU8+aNajKbSf1TzDB1yKPA==} + engines: {node: '>=8.0.0'} + color-convert@1.9.3: resolution: {integrity: sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==} @@ -1964,6 +2215,10 @@ packages: resolution: {integrity: sha512-ZqRXc+tZukToSNmh5C2iWMSoV3X1YUcPbqEM4DkEG5tNQXrQUZCNVGGv3IuicnkMtPfGf3Xtp8WCXs295iQ1pQ==} engines: {node: '>= 0.10.0'} + consola@3.2.3: + resolution: {integrity: sha512-I5qxpzLv+sJhTVEoLYNcTW+bThDCPsit0vLNKShZx6rLtpilNpmmeTPaeqJb9ZE9dV3DGaeby6Vuhrw38WjeyQ==} + engines: {node: ^14.18.0 || >=16.10.0} + content-disposition@0.5.4: resolution: {integrity: sha512-FveZTNuGw04cxlAiWbzi6zTAL/lhehaWbTtgluJh4/E95DqMwTmha3KZN1aAWA8cFIhHzMZUvLevkw5Rqk+tSQ==} engines: {node: '>= 0.6'} @@ -1972,6 +2227,9 @@ packages: resolution: {integrity: sha512-nTjqfcBFEipKdXCv4YDQWCfmcLZKm81ldF0pAopTvyrFGVbcR6P/VAAd5G7N+0tTr8QqiU0tFadD6FK4NtJwOA==} engines: {node: '>= 0.6'} + cookie-es@1.2.2: + resolution: {integrity: sha512-+W7VmiVINB+ywl1HGXJXmrqkOhpKrIiVZV6tQuV54ZyQC7MMuBt81Vc336GMLoHBq5hV/F9eXgt5Mnx0Rha5Fg==} + cookie-signature@1.0.6: resolution: {integrity: sha512-QADzlaHc8icV8I7vbaJXJwod9HWYp8uCqf1xa4OfNu1T7JVxQIrUgOWtHdNDtPiywmFbiS12VjotIXLrKM3orQ==} @@ -2016,6 +2274,9 @@ packages: engines: {node: '>=4.0'} hasBin: true + cross-fetch@4.0.0: + resolution: {integrity: sha512-e4a5N8lVvuLgAWgnCrLr2PP0YyDOTHa9H/Rj54dirp61qXnNq46m82bRhNqIA5VccJtWBvPTFRV3TtvHUKPB1g==} + cross-spawn@5.1.0: resolution: {integrity: sha512-pTgQJ5KC0d2hcY8eyL1IzlBPYjTkyH72XRZPnLyKus2mBfNjQs3klqbJU2VILqZryAZUt9JOb3h/mWMy23/f5A==} @@ -2027,6 +2288,9 @@ packages: resolution: {integrity: sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==} engines: {node: '>= 8'} + crossws@0.3.1: + resolution: {integrity: sha512-HsZgeVYaG+b5zA+9PbIPGq4+J/CJynJuearykPsXx4V/eMhyQ5EDVg3Ak2FBZtVXCiOLu/U7IiwDHTr9MA+IKw==} + crypto-random-string@2.0.0: resolution: {integrity: sha512-v1plID3y9r/lPhviJ1wrXpLeyUIGAZ2SHNYTEapm7/8A9nLPoyvVp3RK/EPFqn5kEznyWgYZNsRtYYIWbuG8KA==} engines: {node: '>=8'} @@ -2112,6 +2376,9 @@ packages: resolution: {integrity: sha512-8QmQKqEASLd5nx0U1B1okLElbUuuttJ/AnYmRXbbbGDWh6uS208EjD4Xqq/I9wK7u0v6O08XhTWnt5XtEbR6Dg==} engines: {node: '>= 0.4'} + defu@6.1.4: + resolution: {integrity: sha512-mEQCMmwJu317oSz8CwdIOdwf3xMif1ttiM8LTufzc3g6kR+9Pe236twL8j3IYT1F7GfRgGcW6MWxzZjLIkuHIg==} + degenerator@5.0.1: resolution: {integrity: sha512-TllpMR/t0M5sqCXfj85i4XaAzxmS5tVA16dqvdkMwGmzI+dXLXnw3J+3Vdv7VKw+ThlTMboK6i9rnZ6Nntj5CQ==} engines: {node: '>= 14'} @@ -2125,6 +2392,10 @@ packages: engines: {node: '>=10'} hasBin: true + depd@1.1.2: + resolution: {integrity: sha512-7emPTl6Dpo6JRXOXjLRxck+FlLRX5847cLKEn00PLAgc3g2hTZZgr+e4c2v6QpSmLeFP3n5yUo7ft6avBK/5jQ==} + engines: {node: '>= 0.6'} + depd@2.0.0: resolution: {integrity: sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==} engines: {node: '>= 0.8'} @@ -2137,6 +2408,9 @@ packages: deps-regex@0.2.0: resolution: {integrity: sha512-PwuBojGMQAYbWkMXOY9Pd/NWCDNHVH12pnS7WHqZkTSeMESe4hwnKKRp0yR87g37113x4JPbo/oIvXY+s/f56Q==} + destr@2.0.3: + resolution: {integrity: sha512-2N3BOUU4gYMpTP24s5rF5iP7BDr7uNTCs4ozw3kf/eKfvWSIu93GEBi5m427YoyJoeOzQ5smuu4nNAPGb8idSQ==} + destroy@1.2.0: resolution: {integrity: sha512-2sJGJTaXIIaR1w4iJSNoN0hnMY7Gpc/n8D4qSCJw8QqFWXf7cuAgnEHxBpweaVcPevC2l3KpjYCx3NypQQgaJg==} engines: {node: '>= 0.8', npm: 1.2.8000 || >= 1.4.16} @@ -2345,6 +2619,11 @@ packages: engines: {node: '>=12'} hasBin: true + esbuild@0.23.1: + resolution: {integrity: sha512-VVNz/9Sa0bs5SELtn3f7qhJCDPCF5oMEl5cO9/SSinpE9hbPVvxbd572HH5AKiP7WD8INO53GgfDDhRjkylHEg==} + engines: {node: '>=18'} + hasBin: true + escalade@3.2.0: resolution: {integrity: sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA==} engines: {node: '>=6'} @@ -2850,6 +3129,9 @@ packages: resolution: {integrity: sha512-g0QYk1dZBxGwk+Ngc+ltRH2IBp2f7zBkBMBJZCDerh6EhlhSR6+9irMCuT/09zD6qkarHUSn529sK/yL4S27mg==} engines: {node: '>= 0.4'} + get-tsconfig@4.8.1: + resolution: {integrity: sha512-k9PN+cFBmaLWtVz29SkUoqU5O0slLuHJXt/2P+tMVFT+phsSGXGkp9t3rQIqdz0e+06EHNGs3oM6ZX1s2zHxRg==} + get-uri@6.0.3: resolution: {integrity: sha512-BzUrJBS9EcUb4cFol8r4W3v1cPsSyajLSthNkz5BxbpDcHN5tIrM10E2eNvfnvBn3DaT3DUgx0OpsBKkaOpanw==} engines: {node: '>= 14'} @@ -2950,6 +3232,9 @@ packages: resolution: {integrity: sha512-pCcEwRi+TKpMlxAQObHDQ56KawURgyAf6jtIY046fJ5tIv3zDe/LEIubckAO8fj6JnAxLdmWkUfNyulQ2iKdEw==} engines: {node: '>=14.0.0'} + h3@1.13.0: + resolution: {integrity: sha512-vFEAu/yf8UMUcB4s43OaDaigcqpQd14yanmOsn+NcRX3/guSKncyE2rOYhq8RIchgJrPSs/QiIddnTTR1ddiAg==} + has-bigints@1.0.2: resolution: {integrity: sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==} @@ -3092,6 +3377,10 @@ packages: indexes-of@1.0.1: resolution: {integrity: sha512-bup+4tap3Hympa+JBJUG7XuOsdNQ6fxt0MHyXMKuLBKn0OqsTfvUxkUrroEX1+B2VsSHvCjiIcZVxRtYa4nllA==} + inflation@2.1.0: + resolution: {integrity: sha512-t54PPJHG1Pp7VQvxyVCJ9mBbjG3Hqryges9bXoOO6GExCPa+//i/d5GSuFtpx3ALLd7lgIAur6zrIlBQyJuMlQ==} + engines: {node: '>= 0.8.0'} + inflight@1.0.6: resolution: {integrity: sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==} deprecated: This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful. @@ -3136,6 +3425,9 @@ packages: resolution: {integrity: sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g==} engines: {node: '>= 0.10'} + iron-webcrypto@1.2.1: + resolution: {integrity: sha512-feOM6FaSr6rEABp/eDfVseKyTMDt+KGpeB35SkVn9Tyn0CqvVsY3EwI0v5i8nMHyJnzCIQf7nsy3p41TPkJZhg==} + is-array-buffer@3.0.4: resolution: {integrity: sha512-wcjaerHw0ydZwfhiKbXJWLDY8A7yV7KhjQOpb83hGgGfId/aQa4TOvwyzn2PuswW2gPCYEL/nEAiSVpdOj1lXw==} engines: {node: '>= 0.4'} @@ -3933,6 +4225,9 @@ packages: resolution: {integrity: sha512-E2WEOVsgs7O16zsURJ/eH8BqhF029wGpEOnv7Urwdo2wmQanOACwJQh0devF9D9RhoZru0+9JXIS0dBXIAz+lA==} engines: {node: '>=18'} + node-fetch-native@1.6.4: + resolution: {integrity: sha512-IhOigYzAKHd244OC0JIMIUrjzctirCmPkaIfhDeGcEETWof5zKYUW7e7MYvChGWh/4CJeXEgsRyGzuF334rOOQ==} + node-fetch@2.7.0: resolution: {integrity: sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==} engines: {node: 4.x || >=6.0.0} @@ -3951,6 +4246,18 @@ packages: engines: {node: ^16.14.0 || >=18.0.0} hasBin: true + node-mocks-http@1.16.1: + resolution: {integrity: sha512-Q2m5bmIE1KFeeKI6OsSn+c4XDara5NWnUJgzqnIkhiCNukYX+fqu0ADSeKOlpWtbCwgRnJ69F+7RUiQltzTKXA==} + engines: {node: '>=14'} + peerDependencies: + '@types/express': ^4.17.21 || ^5.0.0 + '@types/node': '*' + peerDependenciesMeta: + '@types/express': + optional: true + '@types/node': + optional: true + node-source-walk@4.3.0: resolution: {integrity: sha512-8Q1hXew6ETzqKRAs3jjLioSxNfT1cx74ooiF8RlAONwVMcfq+UdzLC2eB5qcPldUxaE5w3ytLkrmV1TGddhZTA==} engines: {node: '>=6.0'} @@ -4031,6 +4338,9 @@ packages: obliterator@2.0.4: resolution: {integrity: sha512-lgHwxlxV1qIg1Eap7LgIeoBWIMFibOjbrYPIPJZcI1mmGAI2m3lNYpK12Y+GBdPQ0U1hRwSord7GIaawz962qQ==} + ohash@1.1.4: + resolution: {integrity: sha512-FlDryZAahJmEF3VR3w1KogSEdWX3WhA5GPakFx4J81kEAiHyLMpdLLElS8n8dfNadMgAne/MywcvmogzscVt4g==} + on-finished@2.3.0: resolution: {integrity: sha512-ikqdkGAAyf/X/gPhXGvfgAytDZtDbr+bkNUJ0N9h5MI/dmdgCs3l6hoHrcUv41sRKew3jIwrp4qQDXiK99Utww==} engines: {node: '>= 0.8'} @@ -4061,6 +4371,9 @@ packages: resolution: {integrity: sha512-IFenVPgF70fSm1keSd2iDBIDIBZkroLeuffXq+wKTzTJlBpesFWojV9lb8mzOfaAzM1sr7HQHuO0vtV0zYekGg==} engines: {node: '>=8'} + openapi-types@12.1.3: + resolution: {integrity: sha512-N4YtSYJqghVu4iek2ZUvcN/0aqH1kRDuNqzcycDxhOUpg7GdvLa2F3DgS6yBNhInhv2r/6I0Flkn7CqL8+nIcw==} + openapi3-ts@3.2.0: resolution: {integrity: sha512-/ykNWRV5Qs0Nwq7Pc0nJ78fgILvOT/60OxEmB3v7yQ8a8Bwcm43D4diaYazG/KBn6czA+52XYy931WFLMCUeSg==} @@ -4452,6 +4765,9 @@ packages: quote-unquote@1.0.0: resolution: {integrity: sha512-twwRO/ilhlG/FIgYeKGFqyHhoEhqgnKVkcmqMKi2r524gz3ZbDTcyFt38E9xjJI2vT+KbRNHVbnJ/e0I25Azwg==} + radix3@1.1.2: + resolution: {integrity: sha512-b484I/7b8rDEdSDKckSSBA8knMpcdsXudlE/LNL639wFoHKwLbEkQFZHWEYwDC0wa0FKUcCY+GAF73Z7wxNVFA==} + railroad-diagrams@1.0.0: resolution: {integrity: sha512-cz93DjNeLY0idrCNOH6PviZGRN9GJhsdm9hpn1YCS879fj4W+x5IFJhhkRZcwVgMmFF7R82UA/7Oh+R8lLZg6A==} @@ -4580,6 +4896,9 @@ packages: resolution: {integrity: sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==} engines: {node: '>=8'} + resolve-pkg-maps@1.0.0: + resolution: {integrity: sha512-seS2Tj26TBVOC2NIc2rOe2y2ZO7efxITtLZcGSOnHHNOQ7CkiUBfw0Iw2ck6xkIhPwLhKNLS8BO+hEpngQlqzw==} + resolve@1.22.8: resolution: {integrity: sha512-oKWePCxqpd6FlLvGV1VU0x7bkPmmCNolxzjMf4NczoDnQcIWrAF+cPtZn5i6n+RfD2d9i0tzpKnG6Yk168yIyw==} hasBin: true @@ -5097,6 +5416,12 @@ packages: resolution: {integrity: sha512-aZbgViZrg1QNcG+LULa7nhZpJTZSLm/mXnHXnbAbjmN5aSa0y7V+wvv6+4WaBtpISJzThKy+PIPxc1Nq1EJ9mg==} engines: {node: '>= 14.0.0'} + trpc-openapi@1.2.0: + resolution: {integrity: sha512-pfYoCd/3KYXWXvUPZBKJw455OOwngKN/6SIcj7Yit19OMLJ+8yVZkEvGEeg5wUSwfsiTdRsKuvqkRPXVSwV7ew==} + peerDependencies: + '@trpc/server': ^10.0.0 + zod: ^3.14.4 + ts-node@10.9.2: resolution: {integrity: sha512-f0FFpIdcHgn8zcPSbf1dRevwt047YMnaiJM3u2w2RewrB+fob/zePZcrOyQoLMMO7aBIddLcQIEK5dYjkLnGrQ==} hasBin: true @@ -5133,6 +5458,11 @@ packages: peerDependencies: typescript: '>=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta' + tsx@4.19.2: + resolution: {integrity: sha512-pOUl6Vo2LUq/bSa8S5q7b91cgNSjctn9ugq/+Mvow99qW6x/UZYwzxy/3NmqoT66eHYfCVvFvACC58UBPFf28g==} + engines: {node: '>=18.0.0'} + hasBin: true + tunnel-agent@0.6.0: resolution: {integrity: sha512-McnNiV1l8RYeY8tBgEpuodCC1mLUdbSN+CYBL7kJsJNInOP8UjDDEwdk6Mw60vdLLrr5NHKZhMAOSrR2NZuQ+w==} @@ -5225,6 +5555,9 @@ packages: unbox-primitive@1.0.2: resolution: {integrity: sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==} + uncrypto@0.1.3: + resolution: {integrity: sha512-Ql87qFHB3s/De2ClA9e0gsnS6zXG27SkTiSJwjCc9MebbfapQfuPzumMIUMi38ezPZVNFcHI9sUIepeQfw8J8Q==} + undici-types@6.19.8: resolution: {integrity: sha512-ve2KP6f/JnbPBFyobGHuerC9g1FYGn/F8n1LWTwNxCEzd6IfqTwUQcNXgEtmmQ6DlRrC1hrSrBnCZPokRrDHjw==} @@ -5232,6 +5565,9 @@ packages: resolution: {integrity: sha512-HR3W/bMGPSr90i8AAp2C4DM3wChFdJPLrWYpIS++LxS8K+W535qftjt+4MyjNYHeWabMj1nvtmLIi7l++iq91A==} engines: {node: '>=18.17'} + unenv@1.10.0: + resolution: {integrity: sha512-wY5bskBQFL9n3Eca5XnhH6KbUo/tfvkwm9OpcdCvLaeA7piBNbavbOKJySEwQ1V0RH6HvNlSAFRTpvTqgKRQXQ==} + unicode-emoji-modifier-base@1.0.0: resolution: {integrity: sha512-yLSH4py7oFH3oG/9K+XWrz1pSi3dfUrWEnInbxMfArOfc1+33BlGPQtLsOYwvdMy11AwUBetYuaRxSPqgkq+8g==} engines: {node: '>=4'} @@ -5551,6 +5887,11 @@ packages: resolution: {integrity: sha512-zK7YHHz4ZXpW89AHXUPbQVGKI7uvkd3hzusTdotCg1UxyaVtg0zFJSTfW/Dq5f7OBBVnq6cZIaC8Ti4hb6dtCA==} engines: {node: '>= 14'} + zod-to-json-schema@3.23.5: + resolution: {integrity: sha512-5wlSS0bXfF/BrL4jPAbz9da5hDlDptdEppYfe+x4eIJ7jioqKG9uUxOwPzqof09u/XeVdrgFu29lZi+8XNDJtA==} + peerDependencies: + zod: ^3.23.3 + zod@3.22.4: resolution: {integrity: sha512-iC+8Io04lddc+mVqQ9AZ7OQ2MrUKGN+oIQyq1vemgt46jwCwLfhq7/pwnBnNXXXZb8VTVLKwp9EDkx+ryxIWmg==} @@ -5800,138 +6141,210 @@ snapshots: '@esbuild/aix-ppc64@0.21.5': optional: true + '@esbuild/aix-ppc64@0.23.1': + optional: true + '@esbuild/android-arm64@0.19.12': optional: true '@esbuild/android-arm64@0.21.5': optional: true + '@esbuild/android-arm64@0.23.1': + optional: true + '@esbuild/android-arm@0.19.12': optional: true '@esbuild/android-arm@0.21.5': optional: true + '@esbuild/android-arm@0.23.1': + optional: true + '@esbuild/android-x64@0.19.12': optional: true '@esbuild/android-x64@0.21.5': optional: true + '@esbuild/android-x64@0.23.1': + optional: true + '@esbuild/darwin-arm64@0.19.12': optional: true '@esbuild/darwin-arm64@0.21.5': optional: true + '@esbuild/darwin-arm64@0.23.1': + optional: true + '@esbuild/darwin-x64@0.19.12': optional: true '@esbuild/darwin-x64@0.21.5': optional: true + '@esbuild/darwin-x64@0.23.1': + optional: true + '@esbuild/freebsd-arm64@0.19.12': optional: true '@esbuild/freebsd-arm64@0.21.5': optional: true + '@esbuild/freebsd-arm64@0.23.1': + optional: true + '@esbuild/freebsd-x64@0.19.12': optional: true '@esbuild/freebsd-x64@0.21.5': optional: true + '@esbuild/freebsd-x64@0.23.1': + optional: true + '@esbuild/linux-arm64@0.19.12': optional: true '@esbuild/linux-arm64@0.21.5': optional: true + '@esbuild/linux-arm64@0.23.1': + optional: true + '@esbuild/linux-arm@0.19.12': optional: true '@esbuild/linux-arm@0.21.5': optional: true + '@esbuild/linux-arm@0.23.1': + optional: true + '@esbuild/linux-ia32@0.19.12': optional: true '@esbuild/linux-ia32@0.21.5': optional: true + '@esbuild/linux-ia32@0.23.1': + optional: true + '@esbuild/linux-loong64@0.19.12': optional: true '@esbuild/linux-loong64@0.21.5': optional: true + '@esbuild/linux-loong64@0.23.1': + optional: true + '@esbuild/linux-mips64el@0.19.12': optional: true '@esbuild/linux-mips64el@0.21.5': optional: true + '@esbuild/linux-mips64el@0.23.1': + optional: true + '@esbuild/linux-ppc64@0.19.12': optional: true '@esbuild/linux-ppc64@0.21.5': optional: true + '@esbuild/linux-ppc64@0.23.1': + optional: true + '@esbuild/linux-riscv64@0.19.12': optional: true '@esbuild/linux-riscv64@0.21.5': optional: true + '@esbuild/linux-riscv64@0.23.1': + optional: true + '@esbuild/linux-s390x@0.19.12': optional: true '@esbuild/linux-s390x@0.21.5': optional: true + '@esbuild/linux-s390x@0.23.1': + optional: true + '@esbuild/linux-x64@0.19.12': optional: true '@esbuild/linux-x64@0.21.5': optional: true + '@esbuild/linux-x64@0.23.1': + optional: true + '@esbuild/netbsd-x64@0.19.12': optional: true '@esbuild/netbsd-x64@0.21.5': optional: true + '@esbuild/netbsd-x64@0.23.1': + optional: true + + '@esbuild/openbsd-arm64@0.23.1': + optional: true + '@esbuild/openbsd-x64@0.19.12': optional: true '@esbuild/openbsd-x64@0.21.5': optional: true + '@esbuild/openbsd-x64@0.23.1': + optional: true + '@esbuild/sunos-x64@0.19.12': optional: true '@esbuild/sunos-x64@0.21.5': optional: true + '@esbuild/sunos-x64@0.23.1': + optional: true + '@esbuild/win32-arm64@0.19.12': optional: true '@esbuild/win32-arm64@0.21.5': optional: true + '@esbuild/win32-arm64@0.23.1': + optional: true + '@esbuild/win32-ia32@0.19.12': optional: true '@esbuild/win32-ia32@0.21.5': optional: true + '@esbuild/win32-ia32@0.23.1': + optional: true + '@esbuild/win32-x64@0.19.12': optional: true '@esbuild/win32-x64@0.21.5': optional: true + '@esbuild/win32-x64@0.23.1': + optional: true + '@eslint-community/eslint-utils@4.4.1(eslint@8.57.1)': dependencies: eslint: 8.57.1 @@ -6378,6 +6791,8 @@ snapshots: protobufjs: 7.4.0 yargs: 17.7.2 + '@hapi/bourne@3.0.0': {} + '@humanwhocodes/config-array@0.13.0': dependencies: '@humanwhocodes/object-schema': 2.0.3 @@ -6736,6 +7151,18 @@ snapshots: '@tootallnate/quickjs-emscripten@0.23.0': {} + '@trpc/client@11.0.0-next-beta.308(@trpc/server@11.0.0-next-beta.308)': + dependencies: + '@trpc/server': 11.0.0-next-beta.308 + + '@trpc/react-query@11.0.0-next-beta.308(@tanstack/react-query@5.24.8(react@18.3.1))(@trpc/client@11.0.0-next-beta.308(@trpc/server@11.0.0-next-beta.308))(@trpc/server@11.0.0-next-beta.308)': + dependencies: + '@tanstack/react-query': 5.24.8(react@18.3.1) + '@trpc/client': 11.0.0-next-beta.308(@trpc/server@11.0.0-next-beta.308) + '@trpc/server': 11.0.0-next-beta.308 + + '@trpc/server@11.0.0-next-beta.308': {} + '@tsconfig/node10@1.0.11': {} '@tsconfig/node12@1.0.11': {} @@ -7528,6 +7955,14 @@ snapshots: clone@1.0.4: {} + co-body@6.2.0: + dependencies: + '@hapi/bourne': 3.0.0 + inflation: 2.1.0 + qs: 6.13.1 + raw-body: 2.5.2 + type-is: 1.6.18 + color-convert@1.9.3: dependencies: color-name: 1.1.3 @@ -7630,12 +8065,16 @@ snapshots: transitivePeerDependencies: - supports-color + consola@3.2.3: {} + content-disposition@0.5.4: dependencies: safe-buffer: 5.2.1 content-type@1.0.5: {} + cookie-es@1.2.2: {} + cookie-signature@1.0.6: {} cookie@0.7.1: {} @@ -7677,6 +8116,12 @@ snapshots: dependencies: cross-spawn: 6.0.5 + cross-fetch@4.0.0(encoding@0.1.13): + dependencies: + node-fetch: 2.7.0(encoding@0.1.13) + transitivePeerDependencies: + - encoding + cross-spawn@5.1.0: dependencies: lru-cache: 4.1.5 @@ -7697,6 +8142,10 @@ snapshots: shebang-command: 2.0.0 which: 2.0.2 + crossws@0.3.1: + dependencies: + uncrypto: 0.1.3 + crypto-random-string@2.0.0: {} csv-parse@5.6.0: {} @@ -7770,6 +8219,8 @@ snapshots: has-property-descriptors: 1.0.2 object-keys: 1.1.1 + defu@6.1.4: {} + degenerator@5.0.1: dependencies: ast-types: 0.13.4 @@ -7806,6 +8257,8 @@ snapshots: transitivePeerDependencies: - supports-color + depd@1.1.2: {} + depd@2.0.0: {} dependency-tree@8.1.2: @@ -7820,6 +8273,8 @@ snapshots: deps-regex@0.2.0: {} + destr@2.0.3: {} + destroy@1.2.0: {} detect-file@1.0.0: {} @@ -8189,6 +8644,33 @@ snapshots: '@esbuild/win32-ia32': 0.21.5 '@esbuild/win32-x64': 0.21.5 + esbuild@0.23.1: + optionalDependencies: + '@esbuild/aix-ppc64': 0.23.1 + '@esbuild/android-arm': 0.23.1 + '@esbuild/android-arm64': 0.23.1 + '@esbuild/android-x64': 0.23.1 + '@esbuild/darwin-arm64': 0.23.1 + '@esbuild/darwin-x64': 0.23.1 + '@esbuild/freebsd-arm64': 0.23.1 + '@esbuild/freebsd-x64': 0.23.1 + '@esbuild/linux-arm': 0.23.1 + '@esbuild/linux-arm64': 0.23.1 + '@esbuild/linux-ia32': 0.23.1 + '@esbuild/linux-loong64': 0.23.1 + '@esbuild/linux-mips64el': 0.23.1 + '@esbuild/linux-ppc64': 0.23.1 + '@esbuild/linux-riscv64': 0.23.1 + '@esbuild/linux-s390x': 0.23.1 + '@esbuild/linux-x64': 0.23.1 + '@esbuild/netbsd-x64': 0.23.1 + '@esbuild/openbsd-arm64': 0.23.1 + '@esbuild/openbsd-x64': 0.23.1 + '@esbuild/sunos-x64': 0.23.1 + '@esbuild/win32-arm64': 0.23.1 + '@esbuild/win32-ia32': 0.23.1 + '@esbuild/win32-x64': 0.23.1 + escalade@3.2.0: {} escape-goat@2.1.1: {} @@ -8957,6 +9439,10 @@ snapshots: es-errors: 1.3.0 get-intrinsic: 1.2.4 + get-tsconfig@4.8.1: + dependencies: + resolve-pkg-maps: 1.0.0 + get-uri@6.0.3: dependencies: basic-ftp: 5.0.5 @@ -9123,6 +9609,19 @@ snapshots: - encoding - supports-color + h3@1.13.0: + dependencies: + cookie-es: 1.2.2 + crossws: 0.3.1 + defu: 6.1.4 + destr: 2.0.3 + iron-webcrypto: 1.2.1 + ohash: 1.1.4 + radix3: 1.1.2 + ufo: 1.5.4 + uncrypto: 0.1.3 + unenv: 1.10.0 + has-bigints@1.0.2: {} has-flag@3.0.0: {} @@ -9255,6 +9754,8 @@ snapshots: indexes-of@1.0.1: {} + inflation@2.1.0: {} + inflight@1.0.6: dependencies: once: 1.4.0 @@ -9311,6 +9812,8 @@ snapshots: ipaddr.js@1.9.1: {} + iron-webcrypto@1.2.1: {} + is-array-buffer@3.0.4: dependencies: call-bind: 1.0.7 @@ -9949,8 +10452,7 @@ snapshots: mime@2.6.0: {} - mime@3.0.0: - optional: true + mime@3.0.0: {} mimic-fn@2.1.0: {} @@ -10127,6 +10629,8 @@ snapshots: emojilib: 2.4.0 skin-tone: 2.0.0 + node-fetch-native@1.6.4: {} + node-fetch@2.7.0(encoding@0.1.13): dependencies: whatwg-url: 5.0.0 @@ -10151,6 +10655,22 @@ snapshots: - supports-color optional: true + node-mocks-http@1.16.1(@types/express@4.17.21)(@types/node@20.16.5): + dependencies: + accepts: 1.3.8 + content-disposition: 0.5.4 + depd: 1.1.2 + fresh: 0.5.2 + merge-descriptors: 1.0.3 + methods: 1.1.2 + mime: 1.6.0 + parseurl: 1.3.3 + range-parser: 1.2.1 + type-is: 1.6.18 + optionalDependencies: + '@types/express': 4.17.21 + '@types/node': 20.16.5 + node-source-walk@4.3.0: dependencies: '@babel/parser': 7.25.6 @@ -10242,6 +10762,8 @@ snapshots: obliterator@2.0.4: {} + ohash@1.1.4: {} + on-finished@2.3.0: dependencies: ee-first: 1.1.1 @@ -10272,6 +10794,8 @@ snapshots: dependencies: is-wsl: 1.1.0 + openapi-types@12.1.3: {} + openapi3-ts@3.2.0: dependencies: yaml: 2.6.1 @@ -10676,6 +11200,8 @@ snapshots: quote-unquote@1.0.0: {} + radix3@1.1.2: {} + railroad-diagrams@1.0.0: {} randexp@0.4.6: @@ -10830,6 +11356,8 @@ snapshots: resolve-from@5.0.0: {} + resolve-pkg-maps@1.0.0: {} + resolve@1.22.8: dependencies: is-core-module: 2.15.1 @@ -11448,6 +11976,20 @@ snapshots: triple-beam@1.4.1: {} + trpc-openapi@1.2.0(@trpc/server@11.0.0-next-beta.308)(@types/express@4.17.21)(@types/node@20.16.5)(zod@3.22.4): + dependencies: + '@trpc/server': 11.0.0-next-beta.308 + co-body: 6.2.0 + h3: 1.13.0 + lodash.clonedeep: 4.5.0 + node-mocks-http: 1.16.1(@types/express@4.17.21)(@types/node@20.16.5) + openapi-types: 12.1.3 + zod: 3.22.4 + zod-to-json-schema: 3.23.5(zod@3.22.4) + transitivePeerDependencies: + - '@types/express' + - '@types/node' + ts-node@10.9.2(@types/node@22.9.3)(typescript@5.4.5): dependencies: '@cspotcode/source-map-support': 0.8.1 @@ -11491,6 +12033,13 @@ snapshots: tslib: 1.14.1 typescript: 5.4.5 + tsx@4.19.2: + dependencies: + esbuild: 0.23.1 + get-tsconfig: 4.8.1 + optionalDependencies: + fsevents: 2.3.3 + tunnel-agent@0.6.0: dependencies: safe-buffer: 5.2.1 @@ -11586,10 +12135,20 @@ snapshots: has-symbols: 1.0.3 which-boxed-primitive: 1.0.2 + uncrypto@0.1.3: {} + undici-types@6.19.8: {} undici@6.19.7: {} + unenv@1.10.0: + dependencies: + consola: 3.2.3 + defu: 6.1.4 + mime: 3.0.0 + node-fetch-native: 1.6.4 + pathe: 1.1.2 + unicode-emoji-modifier-base@1.0.0: {} unicorn-magic@0.1.0: {} @@ -11927,4 +12486,8 @@ snapshots: compress-commons: 6.0.2 readable-stream: 4.5.2 + zod-to-json-schema@3.23.5(zod@3.22.4): + dependencies: + zod: 3.22.4 + zod@3.22.4: {}