@trpc/server 11.0.0-alpha-tmp-export-from-main-nuke-core.239 → 11.0.0-alpha-tmp-export-from-main.220
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/@trpc-server/http.d.ts +2 -0
- package/dist/@trpc-server/http.d.ts.map +1 -0
- package/dist/adapters/aws-lambda/index.d.ts +2 -1
- package/dist/adapters/aws-lambda/index.d.ts.map +1 -1
- package/dist/adapters/aws-lambda/index.js +4 -6
- package/dist/adapters/aws-lambda/index.mjs +2 -4
- package/dist/adapters/aws-lambda/utils.d.ts +3 -2
- package/dist/adapters/aws-lambda/utils.d.ts.map +1 -1
- package/dist/adapters/aws-lambda/utils.js +4 -5
- package/dist/adapters/aws-lambda/utils.mjs +2 -3
- package/dist/adapters/express.d.ts +2 -1
- package/dist/adapters/express.d.ts.map +1 -1
- package/dist/adapters/fastify/fastifyRequestHandler.d.ts +2 -2
- package/dist/adapters/fastify/fastifyRequestHandler.d.ts.map +1 -1
- package/dist/adapters/fastify/fastifyRequestHandler.js +3 -6
- package/dist/adapters/fastify/fastifyRequestHandler.mjs +1 -4
- package/dist/adapters/fastify/fastifyTRPCPlugin.d.ts +2 -1
- package/dist/adapters/fastify/fastifyTRPCPlugin.d.ts.map +1 -1
- package/dist/adapters/fastify/fastifyTRPCPlugin.js +1 -0
- package/dist/adapters/fastify/fastifyTRPCPlugin.mjs +1 -0
- package/dist/adapters/fetch/fetchRequestHandler.d.ts +2 -1
- package/dist/adapters/fetch/fetchRequestHandler.d.ts.map +1 -1
- package/dist/adapters/fetch/fetchRequestHandler.js +4 -6
- package/dist/adapters/fetch/fetchRequestHandler.mjs +2 -4
- package/dist/adapters/fetch/types.d.ts +3 -2
- package/dist/adapters/fetch/types.d.ts.map +1 -1
- package/dist/adapters/next.d.ts +3 -1
- package/dist/adapters/next.d.ts.map +1 -1
- package/dist/adapters/next.js +4 -6
- package/dist/adapters/next.mjs +2 -4
- package/dist/adapters/node-http/content-type/json/getPostBody.d.ts +1 -1
- package/dist/adapters/node-http/content-type/json/getPostBody.d.ts.map +1 -1
- package/dist/adapters/node-http/content-type/json/getPostBody.js +2 -4
- package/dist/adapters/node-http/content-type/json/getPostBody.mjs +1 -3
- package/dist/adapters/node-http/content-type/json/index.js +2 -4
- package/dist/adapters/node-http/content-type/json/index.mjs +1 -3
- package/dist/adapters/node-http/internals/contentType.d.ts +2 -2
- package/dist/adapters/node-http/internals/contentType.d.ts.map +1 -1
- package/dist/adapters/node-http/nodeHTTPRequestHandler.d.ts +2 -1
- package/dist/adapters/node-http/nodeHTTPRequestHandler.d.ts.map +1 -1
- package/dist/adapters/node-http/nodeHTTPRequestHandler.js +4 -6
- package/dist/adapters/node-http/nodeHTTPRequestHandler.mjs +2 -4
- package/dist/adapters/node-http/types.d.ts +4 -3
- package/dist/adapters/node-http/types.d.ts.map +1 -1
- package/dist/adapters/standalone.d.ts +2 -1
- package/dist/adapters/standalone.d.ts.map +1 -1
- package/dist/adapters/standalone.js +0 -1
- package/dist/adapters/standalone.mjs +0 -1
- package/dist/adapters/ws.d.ts +2 -3
- package/dist/adapters/ws.d.ts.map +1 -1
- package/dist/adapters/ws.js +26 -33
- package/dist/adapters/ws.mjs +1 -8
- package/dist/http.d.ts +6 -1
- package/dist/http.d.ts.map +1 -1
- package/dist/http.js +21 -11
- package/dist/http.mjs +1 -6
- package/dist/index.d.ts +70 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +45 -18
- package/dist/index.mjs +1 -8
- package/dist/observable.d.ts +3 -0
- package/dist/observable.d.ts.map +1 -0
- package/dist/observable.js +30 -0
- package/dist/observable.mjs +1 -0
- package/dist/rpc.d.ts +2 -1
- package/dist/rpc.d.ts.map +1 -1
- package/dist/rpc.js +13 -6
- package/dist/rpc.mjs +1 -3
- package/dist/shared.d.ts +1 -1
- package/dist/shared.d.ts.map +1 -1
- package/dist/shared.js +9 -6
- package/dist/shared.mjs +1 -4
- package/dist/unstableDontImportMe.d.ts +10 -0
- package/dist/unstableDontImportMe.d.ts.map +1 -0
- package/dist/unstableDontImportMe.js +142 -0
- package/dist/unstableDontImportMe.mjs +1 -0
- package/package.json +135 -52
- package/src/@trpc-server/http.ts +2 -0
- package/src/adapters/aws-lambda/index.ts +5 -4
- package/src/adapters/aws-lambda/utils.ts +4 -3
- package/src/adapters/express.ts +3 -1
- package/src/adapters/fastify/fastifyRequestHandler.ts +4 -6
- package/src/adapters/fastify/fastifyTRPCPlugin.ts +2 -1
- package/src/adapters/fetch/fetchRequestHandler.ts +4 -6
- package/src/adapters/fetch/types.ts +3 -2
- package/src/adapters/next.ts +4 -2
- package/src/adapters/node-http/content-type/form-data/index.ts +1 -1
- package/src/adapters/node-http/content-type/json/getPostBody.ts +2 -2
- package/src/adapters/node-http/content-type/json/index.ts +1 -1
- package/src/adapters/node-http/internals/contentType.ts +2 -2
- package/src/adapters/node-http/nodeHTTPRequestHandler.ts +4 -6
- package/src/adapters/node-http/types.ts +5 -4
- package/src/adapters/standalone.ts +2 -2
- package/src/adapters/ws.ts +13 -14
- package/src/http.ts +26 -1
- package/src/index.ts +109 -1
- package/src/observable.ts +16 -0
- package/src/rpc.ts +26 -1
- package/src/shared.ts +1 -1
- package/src/unstableDontImportMe.ts +146 -0
- package/unstableDontImportMe/index.d.ts +1 -0
- package/unstableDontImportMe/index.js +1 -0
- package/dist/@trpc/server/http.d.ts +0 -7
- package/dist/@trpc/server/http.d.ts.map +0 -1
- package/dist/@trpc/server/index.d.ts +0 -69
- package/dist/@trpc/server/index.d.ts.map +0 -1
- package/dist/@trpc/server/rpc.d.ts +0 -3
- package/dist/@trpc/server/rpc.d.ts.map +0 -1
- package/dist/bundle-analysis.json +0 -757
- package/dist/observable/index.d.ts +0 -5
- package/dist/observable/index.d.ts.map +0 -1
- package/dist/observable/index.js +0 -13
- package/dist/observable/index.mjs +0 -2
- package/dist/observable/observable.d.ts +0 -13
- package/dist/observable/observable.d.ts.map +0 -1
- package/dist/observable/observable.js +0 -126
- package/dist/observable/observable.mjs +0 -122
- package/dist/observable/operators.d.ts +0 -8
- package/dist/observable/operators.d.ts.map +0 -1
- package/dist/observable/operators.js +0 -103
- package/dist/observable/operators.mjs +0 -99
- package/dist/observable/types.d.ts +0 -26
- package/dist/observable/types.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/TRPCInferrable.d.ts +0 -6
- package/dist/unstable-core-do-not-import/TRPCInferrable.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/createProxy.d.ts +0 -19
- package/dist/unstable-core-do-not-import/createProxy.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/createProxy.js +0 -52
- package/dist/unstable-core-do-not-import/createProxy.mjs +0 -49
- package/dist/unstable-core-do-not-import/error/TRPCError.d.ts +0 -13
- package/dist/unstable-core-do-not-import/error/TRPCError.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/error/TRPCError.js +0 -67
- package/dist/unstable-core-do-not-import/error/TRPCError.mjs +0 -63
- package/dist/unstable-core-do-not-import/error/formatter.d.ts +0 -33
- package/dist/unstable-core-do-not-import/error/formatter.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/error/formatter.js +0 -7
- package/dist/unstable-core-do-not-import/error/formatter.mjs +0 -5
- package/dist/unstable-core-do-not-import/error/getErrorShape.d.ts +0 -15
- package/dist/unstable-core-do-not-import/error/getErrorShape.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/error/getErrorShape.js +0 -31
- package/dist/unstable-core-do-not-import/error/getErrorShape.mjs +0 -29
- package/dist/unstable-core-do-not-import/http/batchStreamFormatter.d.ts +0 -24
- package/dist/unstable-core-do-not-import/http/batchStreamFormatter.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/http/batchStreamFormatter.js +0 -32
- package/dist/unstable-core-do-not-import/http/batchStreamFormatter.mjs +0 -30
- package/dist/unstable-core-do-not-import/http/contentType.d.ts +0 -29
- package/dist/unstable-core-do-not-import/http/contentType.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/http/contentType.js +0 -54
- package/dist/unstable-core-do-not-import/http/contentType.mjs +0 -52
- package/dist/unstable-core-do-not-import/http/getHTTPStatusCode.d.ts +0 -5
- package/dist/unstable-core-do-not-import/http/getHTTPStatusCode.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/http/getHTTPStatusCode.js +0 -51
- package/dist/unstable-core-do-not-import/http/getHTTPStatusCode.mjs +0 -48
- package/dist/unstable-core-do-not-import/http/index.d.ts +0 -7
- package/dist/unstable-core-do-not-import/http/index.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/http/resolveHTTPResponse.d.ts +0 -51
- package/dist/unstable-core-do-not-import/http/resolveHTTPResponse.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/http/resolveHTTPResponse.js +0 -295
- package/dist/unstable-core-do-not-import/http/resolveHTTPResponse.mjs +0 -293
- package/dist/unstable-core-do-not-import/http/types.d.ts +0 -96
- package/dist/unstable-core-do-not-import/http/types.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/index.d.ts +0 -37
- package/dist/unstable-core-do-not-import/index.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/index.js +0 -48
- package/dist/unstable-core-do-not-import/index.mjs +0 -16
- package/dist/unstable-core-do-not-import/initTRPC.d.ts +0 -96
- package/dist/unstable-core-do-not-import/initTRPC.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/initTRPC.js +0 -95
- package/dist/unstable-core-do-not-import/initTRPC.mjs +0 -93
- package/dist/unstable-core-do-not-import/middleware.d.ts +0 -105
- package/dist/unstable-core-do-not-import/middleware.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/middleware.js +0 -95
- package/dist/unstable-core-do-not-import/middleware.mjs +0 -89
- package/dist/unstable-core-do-not-import/parser.d.ts +0 -30
- package/dist/unstable-core-do-not-import/parser.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/parser.js +0 -37
- package/dist/unstable-core-do-not-import/parser.mjs +0 -35
- package/dist/unstable-core-do-not-import/procedure.d.ts +0 -72
- package/dist/unstable-core-do-not-import/procedure.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/procedure.js +0 -9
- package/dist/unstable-core-do-not-import/procedure.mjs +0 -7
- package/dist/unstable-core-do-not-import/procedureBuilder.d.ts +0 -101
- package/dist/unstable-core-do-not-import/procedureBuilder.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/procedureBuilder.js +0 -176
- package/dist/unstable-core-do-not-import/procedureBuilder.mjs +0 -173
- package/dist/unstable-core-do-not-import/rootConfig.d.ts +0 -75
- package/dist/unstable-core-do-not-import/rootConfig.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/rootConfig.js +0 -8
- package/dist/unstable-core-do-not-import/rootConfig.mjs +0 -6
- package/dist/unstable-core-do-not-import/router.d.ts +0 -85
- package/dist/unstable-core-do-not-import/router.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/router.js +0 -156
- package/dist/unstable-core-do-not-import/router.mjs +0 -151
- package/dist/unstable-core-do-not-import/rpc/codes.d.ts +0 -51
- package/dist/unstable-core-do-not-import/rpc/codes.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/rpc/codes.js +0 -38
- package/dist/unstable-core-do-not-import/rpc/codes.mjs +0 -35
- package/dist/unstable-core-do-not-import/rpc/envelopes.d.ts +0 -97
- package/dist/unstable-core-do-not-import/rpc/envelopes.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/rpc/index.d.ts +0 -5
- package/dist/unstable-core-do-not-import/rpc/index.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/rpc/parseTRPCMessage.d.ts +0 -5
- package/dist/unstable-core-do-not-import/rpc/parseTRPCMessage.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/rpc/parseTRPCMessage.js +0 -59
- package/dist/unstable-core-do-not-import/rpc/parseTRPCMessage.mjs +0 -57
- package/dist/unstable-core-do-not-import/serialize.d.ts +0 -62
- package/dist/unstable-core-do-not-import/serialize.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/transformer.d.ts +0 -107
- package/dist/unstable-core-do-not-import/transformer.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/transformer.js +0 -107
- package/dist/unstable-core-do-not-import/transformer.mjs +0 -102
- package/dist/unstable-core-do-not-import/types.d.ts +0 -98
- package/dist/unstable-core-do-not-import/types.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/utils.d.ts +0 -27
- package/dist/unstable-core-do-not-import/utils.d.ts.map +0 -1
- package/dist/unstable-core-do-not-import/utils.js +0 -44
- package/dist/unstable-core-do-not-import/utils.mjs +0 -39
- package/src/@trpc/server/http.ts +0 -26
- package/src/@trpc/server/index.ts +0 -105
- package/src/@trpc/server/rpc.ts +0 -26
- package/src/observable/index.ts +0 -10
- package/src/observable/observable.ts +0 -158
- package/src/observable/operators.ts +0 -119
- package/src/observable/types.ts +0 -76
- package/src/unstable-core-do-not-import/TRPCInferrable.ts +0 -9
- package/src/unstable-core-do-not-import/createProxy.ts +0 -59
- package/src/unstable-core-do-not-import/error/TRPCError.ts +0 -82
- package/src/unstable-core-do-not-import/error/formatter.ts +0 -51
- package/src/unstable-core-do-not-import/error/getErrorShape.ts +0 -36
- package/src/unstable-core-do-not-import/http/batchStreamFormatter.ts +0 -29
- package/src/unstable-core-do-not-import/http/contentType.ts +0 -99
- package/src/unstable-core-do-not-import/http/getHTTPStatusCode.ts +0 -57
- package/src/unstable-core-do-not-import/http/index.ts +0 -23
- package/src/unstable-core-do-not-import/http/resolveHTTPResponse.ts +0 -458
- package/src/unstable-core-do-not-import/http/types.ts +0 -111
- package/src/unstable-core-do-not-import/index.ts +0 -110
- package/src/unstable-core-do-not-import/initTRPC.ts +0 -206
- package/src/unstable-core-do-not-import/middleware.ts +0 -233
- package/src/unstable-core-do-not-import/parser.ts +0 -94
- package/src/unstable-core-do-not-import/procedure.ts +0 -108
- package/src/unstable-core-do-not-import/procedureBuilder.ts +0 -458
- package/src/unstable-core-do-not-import/rootConfig.ts +0 -90
- package/src/unstable-core-do-not-import/router.ts +0 -370
- package/src/unstable-core-do-not-import/rpc/codes.ts +0 -44
- package/src/unstable-core-do-not-import/rpc/envelopes.ts +0 -136
- package/src/unstable-core-do-not-import/rpc/index.ts +0 -21
- package/src/unstable-core-do-not-import/rpc/parseTRPCMessage.ts +0 -85
- package/src/unstable-core-do-not-import/serialize.ts +0 -122
- package/src/unstable-core-do-not-import/transformer.ts +0 -202
- package/src/unstable-core-do-not-import/types.ts +0 -151
- package/src/unstable-core-do-not-import/utils.ts +0 -59
- package/unstable-core-do-not-import/index.d.ts +0 -1
- package/unstable-core-do-not-import/index.js +0 -1
|
@@ -14,7 +14,7 @@ import { Readable } from 'node:stream';
|
|
|
14
14
|
// @ts-ignore the type definitions for this package are borked
|
|
15
15
|
import { streamMultipart } from '@web3-storage/multipart-parser';
|
|
16
16
|
// @trpc/server
|
|
17
|
-
import type { CombinedDataTransformer } from '
|
|
17
|
+
import type { CombinedDataTransformer } from '../../../..';
|
|
18
18
|
import { createNodeHTTPContentTypeHandler } from '../../internals/contentType';
|
|
19
19
|
import type { NodeHTTPRequest } from '../../types';
|
|
20
20
|
import { NodeOnDiskFile } from './fileUploadHandler';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// @trpc/server
|
|
2
|
-
import { TRPCError } from '
|
|
3
|
-
import type { BodyResult } from '
|
|
2
|
+
import { TRPCError } from '../../../..';
|
|
3
|
+
import type { BodyResult } from '../../../../http';
|
|
4
4
|
import type { NodeHTTPRequest } from '../../types';
|
|
5
5
|
|
|
6
6
|
export async function getPostBody(opts: {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// @trpc/server
|
|
2
|
-
import type { AnyRouter } from '
|
|
2
|
+
import type { AnyRouter } from '../../..';
|
|
3
3
|
// @trpc/server/http
|
|
4
|
-
import type { BaseContentTypeHandler } from '../../../@trpc
|
|
4
|
+
import type { BaseContentTypeHandler } from '../../../@trpc-server/http';
|
|
5
5
|
import type {
|
|
6
6
|
NodeHTTPRequest,
|
|
7
7
|
NodeHTTPRequestHandlerOptions,
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* If you're making an adapter for tRPC and looking at this file for reference, you should import types and functions from `@trpc/server` and `@trpc/server/http`
|
|
3
3
|
*
|
|
4
|
+
* Do **not** import from `@trpc/core`
|
|
4
5
|
* @example
|
|
5
6
|
* ```ts
|
|
6
7
|
* import type { AnyTRPCRouter } from '@trpc/server'
|
|
@@ -9,17 +10,14 @@
|
|
|
9
10
|
*/
|
|
10
11
|
/* eslint-disable @typescript-eslint/no-non-null-assertion */
|
|
11
12
|
// @trpc/server
|
|
12
|
-
import type { AnyRouter } from '
|
|
13
|
+
import type { AnyRouter } from '../..';
|
|
13
14
|
import type {
|
|
14
15
|
HTTPRequest,
|
|
15
16
|
HTTPResponse,
|
|
16
17
|
ResolveHTTPRequestOptionsContextFn,
|
|
17
18
|
ResponseChunk,
|
|
18
|
-
} from '
|
|
19
|
-
import {
|
|
20
|
-
getBatchStreamFormatter,
|
|
21
|
-
resolveHTTPResponse,
|
|
22
|
-
} from '../../@trpc/server/http';
|
|
19
|
+
} from '../../http';
|
|
20
|
+
import { getBatchStreamFormatter, resolveHTTPResponse } from '../../http';
|
|
23
21
|
import { nodeHTTPJSONContentTypeHandler } from './content-type/json';
|
|
24
22
|
import type { NodeHTTPContentTypeHandler } from './internals/contentType';
|
|
25
23
|
import type {
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* If you're making an adapter for tRPC and looking at this file for reference, you should import types and functions from `@trpc/server` and `@trpc/server/http`
|
|
3
3
|
*
|
|
4
|
+
* Do **not** import from `@trpc/core`
|
|
4
5
|
* @example
|
|
5
6
|
* ```ts
|
|
6
7
|
* import type { AnyTRPCRouter } from '@trpc/server'
|
|
@@ -8,15 +9,15 @@
|
|
|
8
9
|
* ```
|
|
9
10
|
*/
|
|
10
11
|
import type { IncomingMessage, ServerResponse } from 'http';
|
|
12
|
+
// eslint-disable-next-line no-restricted-imports
|
|
13
|
+
import type { MaybePromise } from '@trpc/core';
|
|
11
14
|
// @trpc/server
|
|
12
|
-
import type { AnyRouter, inferRouterContext } from '
|
|
15
|
+
import type { AnyRouter, inferRouterContext } from '../..';
|
|
13
16
|
// @trpc/server/http
|
|
14
17
|
import type {
|
|
15
18
|
HTTPBaseHandlerOptions,
|
|
16
19
|
TRPCRequestInfo,
|
|
17
|
-
} from '../../@trpc
|
|
18
|
-
// eslint-disable-next-line no-restricted-imports
|
|
19
|
-
import type { MaybePromise } from '../../unstable-core-do-not-import';
|
|
20
|
+
} from '../../@trpc-server/http';
|
|
20
21
|
import type { NodeHTTPContentTypeHandler } from './internals/contentType';
|
|
21
22
|
|
|
22
23
|
interface ParsedQs {
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* If you're making an adapter for tRPC and looking at this file for reference, you should import types and functions from `@trpc/server` and `@trpc/server/http`
|
|
3
3
|
*
|
|
4
|
+
* Do **not** import from `@trpc/core`
|
|
4
5
|
* @example
|
|
5
6
|
* ```ts
|
|
6
7
|
* import type { AnyTRPCRouter } from '@trpc/server'
|
|
@@ -10,7 +11,7 @@
|
|
|
10
11
|
/* eslint-disable @typescript-eslint/no-non-null-assertion */
|
|
11
12
|
import http from 'http';
|
|
12
13
|
// @trpc/server
|
|
13
|
-
import type { AnyRouter } from '
|
|
14
|
+
import type { AnyRouter } from '..';
|
|
14
15
|
import type {
|
|
15
16
|
NodeHTTPCreateContextFnOptions,
|
|
16
17
|
NodeHTTPHandlerOptions,
|
|
@@ -36,7 +37,6 @@ export function createHTTPHandler<TRouter extends AnyRouter>(
|
|
|
36
37
|
await nodeHTTPRequestHandler({
|
|
37
38
|
// FIXME: no typecasting should be needed here
|
|
38
39
|
...(opts as CreateHTTPHandlerOptions<AnyRouter>),
|
|
39
|
-
...(opts as any),
|
|
40
40
|
req,
|
|
41
41
|
res,
|
|
42
42
|
path,
|
package/src/adapters/ws.ts
CHANGED
|
@@ -1,26 +1,25 @@
|
|
|
1
1
|
import type { IncomingMessage } from 'http';
|
|
2
|
+
// eslint-disable-next-line no-restricted-imports
|
|
3
|
+
import type {
|
|
4
|
+
BaseHandlerOptions,
|
|
5
|
+
JSONRPC2,
|
|
6
|
+
MaybePromise,
|
|
7
|
+
TRPCClientOutgoingMessage,
|
|
8
|
+
TRPCReconnectNotification,
|
|
9
|
+
TRPCResponseMessage,
|
|
10
|
+
Unsubscribable,
|
|
11
|
+
} from '@trpc/core';
|
|
2
12
|
import type ws from 'ws';
|
|
3
|
-
import type { AnyRouter, inferRouterContext } from '
|
|
13
|
+
import type { AnyRouter, inferRouterContext } from '..';
|
|
4
14
|
import {
|
|
5
15
|
callProcedure,
|
|
6
16
|
getErrorShape,
|
|
7
17
|
getTRPCErrorFromUnknown,
|
|
8
18
|
transformTRPCResponse,
|
|
9
19
|
TRPCError,
|
|
10
|
-
} from '
|
|
11
|
-
import type { BaseHandlerOptions } from '../@trpc/server/http';
|
|
12
|
-
import { parseTRPCMessage } from '../@trpc/server/rpc';
|
|
13
|
-
// @trpc/server/rpc
|
|
14
|
-
import type {
|
|
15
|
-
JSONRPC2,
|
|
16
|
-
TRPCClientOutgoingMessage,
|
|
17
|
-
TRPCReconnectNotification,
|
|
18
|
-
TRPCResponseMessage,
|
|
19
|
-
} from '../@trpc/server/rpc';
|
|
20
|
+
} from '..';
|
|
20
21
|
import { isObservable } from '../observable';
|
|
21
|
-
import
|
|
22
|
-
// eslint-disable-next-line no-restricted-imports
|
|
23
|
-
import type { MaybePromise } from '../unstable-core-do-not-import';
|
|
22
|
+
import { parseTRPCMessage } from '../rpc';
|
|
24
23
|
import type { NodeHTTPCreateContextFnOptions } from './node-http';
|
|
25
24
|
|
|
26
25
|
/**
|
package/src/http.ts
CHANGED
|
@@ -1 +1,26 @@
|
|
|
1
|
-
export
|
|
1
|
+
export {
|
|
2
|
+
getHTTPStatusCode,
|
|
3
|
+
getHTTPStatusCodeFromError,
|
|
4
|
+
} from './unstableDontImportMe';
|
|
5
|
+
export { resolveHTTPResponse } from './unstableDontImportMe';
|
|
6
|
+
export type {
|
|
7
|
+
BaseHandlerOptions,
|
|
8
|
+
HTTPBaseHandlerOptions,
|
|
9
|
+
HTTPHeaders,
|
|
10
|
+
HTTPRequest,
|
|
11
|
+
HTTPResponse,
|
|
12
|
+
OnErrorFunction,
|
|
13
|
+
ProcedureCall,
|
|
14
|
+
ResolveHTTPRequestOptionsContextFn,
|
|
15
|
+
ResponseChunk,
|
|
16
|
+
ResponseMeta,
|
|
17
|
+
ResponseMetaFn,
|
|
18
|
+
TRPCRequestInfo,
|
|
19
|
+
} from './unstableDontImportMe';
|
|
20
|
+
|
|
21
|
+
export { getBatchStreamFormatter } from './unstableDontImportMe';
|
|
22
|
+
export type {
|
|
23
|
+
BaseContentTypeHandler,
|
|
24
|
+
BodyResult,
|
|
25
|
+
} from './unstableDontImportMe';
|
|
26
|
+
export { getJsonContentTypeInputs } from './unstableDontImportMe';
|
package/src/index.ts
CHANGED
|
@@ -1 +1,109 @@
|
|
|
1
|
-
export
|
|
1
|
+
export {
|
|
2
|
+
TRPCError,
|
|
3
|
+
/**
|
|
4
|
+
* @deprecated use `experimental_trpcMiddleware` instead
|
|
5
|
+
*/
|
|
6
|
+
experimental_standaloneMiddleware,
|
|
7
|
+
experimental_standaloneMiddleware as experimental_trpcMiddleware,
|
|
8
|
+
initTRPC,
|
|
9
|
+
|
|
10
|
+
/** @deprecated - intenral don't use */
|
|
11
|
+
unsetMarker,
|
|
12
|
+
|
|
13
|
+
// --- FIXME a bunch of these exports are only useful for plugins - move them somewhere else? ----
|
|
14
|
+
callProcedure as callTRPCProcedure,
|
|
15
|
+
getTRPCErrorFromUnknown,
|
|
16
|
+
transformTRPCResponse,
|
|
17
|
+
createFlatProxy as createTRPCFlatProxy,
|
|
18
|
+
type inferProcedureInput,
|
|
19
|
+
type inferProcedureOutput,
|
|
20
|
+
type inferRouterError,
|
|
21
|
+
type inferRouterInputs,
|
|
22
|
+
type inferRouterOutputs,
|
|
23
|
+
type inferRouterContext,
|
|
24
|
+
type inferTransformedProcedureOutput,
|
|
25
|
+
type inferTransformedSubscriptionOutput,
|
|
26
|
+
type AnyProcedure as AnyTRPCProcedure,
|
|
27
|
+
type AnyRouter as AnyTRPCRouter,
|
|
28
|
+
type AnyMiddlewareFunction as AnyTRPCMiddlewareFunction,
|
|
29
|
+
type CombinedDataTransformer as TRPCCombinedDataTransformer,
|
|
30
|
+
type ProcedureType as TRPCProcedureType,
|
|
31
|
+
type AnyMutationProcedure as AnyTRPCMutationProcedure,
|
|
32
|
+
type AnyQueryProcedure as AnyTRPCQueryProcedure,
|
|
33
|
+
type ProcedureRouterRecord as TRPCProcedureRouterRecord,
|
|
34
|
+
type ProcedureArgs as TRPCProcedureArgs,
|
|
35
|
+
type AnySubscriptionProcedure as AnyTRPCSubscriptionProcedure,
|
|
36
|
+
} from '@trpc/core';
|
|
37
|
+
|
|
38
|
+
export type {
|
|
39
|
+
/**
|
|
40
|
+
* @deprecated use `AnyTRPCProcedure` instead
|
|
41
|
+
*/
|
|
42
|
+
AnyProcedure,
|
|
43
|
+
/**
|
|
44
|
+
* @deprecated use `AnyTRPCRouter` instead
|
|
45
|
+
*/
|
|
46
|
+
AnyRouter,
|
|
47
|
+
/**
|
|
48
|
+
* @deprecated use `AnyTRPCMiddlewareFunction` instead
|
|
49
|
+
*/
|
|
50
|
+
AnyMiddlewareFunction,
|
|
51
|
+
/**
|
|
52
|
+
* @deprecated use `TRPCCombinedDataTransformer` instead
|
|
53
|
+
*/
|
|
54
|
+
CombinedDataTransformer,
|
|
55
|
+
|
|
56
|
+
/**
|
|
57
|
+
* @deprecated This is a utility type will be removed in v12
|
|
58
|
+
*/
|
|
59
|
+
Dict,
|
|
60
|
+
|
|
61
|
+
/**
|
|
62
|
+
* @deprecated This is a utility type will be removed in v12
|
|
63
|
+
*/
|
|
64
|
+
DeepPartial,
|
|
65
|
+
/**
|
|
66
|
+
* @deprecated use `TRPCProcedureType` instead
|
|
67
|
+
*/
|
|
68
|
+
ProcedureType,
|
|
69
|
+
/**
|
|
70
|
+
* @deprecated use `AnyTRPCMutationProcedure` instead
|
|
71
|
+
*/
|
|
72
|
+
AnyMutationProcedure,
|
|
73
|
+
|
|
74
|
+
/**
|
|
75
|
+
* @deprecated use `AnyTRPCQueryProcedure` instead
|
|
76
|
+
*/
|
|
77
|
+
AnyQueryProcedure,
|
|
78
|
+
/**
|
|
79
|
+
* @deprecated use `TRPCProcedureRouterRecord` instead
|
|
80
|
+
*/
|
|
81
|
+
ProcedureRouterRecord,
|
|
82
|
+
/**
|
|
83
|
+
* @deprecated use `TRPCProcedureArgs` instead
|
|
84
|
+
*/
|
|
85
|
+
ProcedureArgs,
|
|
86
|
+
/**
|
|
87
|
+
* @deprecated use `AnyTRPCSubscriptionProcedure` instead
|
|
88
|
+
*/
|
|
89
|
+
AnySubscriptionProcedure,
|
|
90
|
+
} from '@trpc/core';
|
|
91
|
+
|
|
92
|
+
export {
|
|
93
|
+
/**
|
|
94
|
+
* @deprecated use `getTRPCErrorShape` instead
|
|
95
|
+
*/
|
|
96
|
+
getErrorShape,
|
|
97
|
+
|
|
98
|
+
/**
|
|
99
|
+
* @deprecated use `callTRPCProcedure` instead
|
|
100
|
+
*/
|
|
101
|
+
callProcedure,
|
|
102
|
+
} from '@trpc/core';
|
|
103
|
+
|
|
104
|
+
/**
|
|
105
|
+
* @deprecated
|
|
106
|
+
* Use `Awaited<ReturnType<typeof myFunction>>` instead
|
|
107
|
+
*/
|
|
108
|
+
export type inferAsyncReturnType<TFunction extends (...args: any[]) => any> =
|
|
109
|
+
Awaited<ReturnType<TFunction>>;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export type {
|
|
2
|
+
Observable,
|
|
3
|
+
Observer,
|
|
4
|
+
TeardownLogic,
|
|
5
|
+
Unsubscribable,
|
|
6
|
+
UnsubscribeFn,
|
|
7
|
+
inferObservableValue,
|
|
8
|
+
} from './unstableDontImportMe';
|
|
9
|
+
export {
|
|
10
|
+
isObservable,
|
|
11
|
+
map,
|
|
12
|
+
observable,
|
|
13
|
+
observableToPromise,
|
|
14
|
+
share,
|
|
15
|
+
tap,
|
|
16
|
+
} from './unstableDontImportMe';
|
package/src/rpc.ts
CHANGED
|
@@ -1 +1,26 @@
|
|
|
1
|
-
|
|
1
|
+
// Note: this should likely be moved to a sort of `@trpc/plugin` package
|
|
2
|
+
export type {
|
|
3
|
+
JSONRPC2,
|
|
4
|
+
TRPCClientIncomingMessage,
|
|
5
|
+
TRPCClientIncomingRequest,
|
|
6
|
+
TRPCClientOutgoingMessage,
|
|
7
|
+
TRPCClientOutgoingRequest,
|
|
8
|
+
TRPCErrorResponse,
|
|
9
|
+
TRPCErrorShape,
|
|
10
|
+
TRPCReconnectNotification,
|
|
11
|
+
TRPCRequest,
|
|
12
|
+
TRPCRequestMessage,
|
|
13
|
+
TRPCResponse,
|
|
14
|
+
TRPCResponseMessage,
|
|
15
|
+
TRPCResult,
|
|
16
|
+
TRPCResultMessage,
|
|
17
|
+
TRPCSubscriptionStopNotification,
|
|
18
|
+
TRPCSuccessResponse,
|
|
19
|
+
TRPC_ERROR_CODE_KEY,
|
|
20
|
+
TRPC_ERROR_CODE_NUMBER,
|
|
21
|
+
} from './unstableDontImportMe';
|
|
22
|
+
export {
|
|
23
|
+
TRPC_ERROR_CODES_BY_KEY,
|
|
24
|
+
TRPC_ERROR_CODES_BY_NUMBER,
|
|
25
|
+
parseTRPCMessage,
|
|
26
|
+
} from './unstableDontImportMe';
|
package/src/shared.ts
CHANGED
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file is here to make TypeScript happy and prevent _"The inferred type of 'createContext' cannot be named without a reference to [...]"_.
|
|
3
|
+
*
|
|
4
|
+
* We're basically just re-exporting everything from @trpc/core here.
|
|
5
|
+
*
|
|
6
|
+
* If you need to import anything from here, please open an issue at https://github.com/trpc/trpc/issues
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
export type {
|
|
10
|
+
AnyMiddlewareFunction,
|
|
11
|
+
AnyRouter,
|
|
12
|
+
AnyMutationProcedure,
|
|
13
|
+
AnyProcedure,
|
|
14
|
+
AnyQueryProcedure,
|
|
15
|
+
AnyRootConfig,
|
|
16
|
+
AnyRouterDef,
|
|
17
|
+
AnySubscriptionProcedure,
|
|
18
|
+
BaseContentTypeHandler,
|
|
19
|
+
BaseHandlerOptions,
|
|
20
|
+
BodyResult,
|
|
21
|
+
CombinedDataTransformer,
|
|
22
|
+
CombinedDataTransformerClient,
|
|
23
|
+
CreateRouterInner,
|
|
24
|
+
DataTransformer,
|
|
25
|
+
DataTransformerOptions,
|
|
26
|
+
DeepPartial,
|
|
27
|
+
DefaultDataTransformer,
|
|
28
|
+
DefaultErrorData,
|
|
29
|
+
DefaultErrorShape,
|
|
30
|
+
Dict,
|
|
31
|
+
DistributiveOmit,
|
|
32
|
+
Filter,
|
|
33
|
+
FilterKeys,
|
|
34
|
+
HTTPBaseHandlerOptions,
|
|
35
|
+
HTTPHeaders,
|
|
36
|
+
HTTPRequest,
|
|
37
|
+
HTTPResponse,
|
|
38
|
+
IntersectionError,
|
|
39
|
+
JSONRPC2,
|
|
40
|
+
Maybe,
|
|
41
|
+
MaybePromise,
|
|
42
|
+
MiddlewareBuilder,
|
|
43
|
+
MiddlewareFunction,
|
|
44
|
+
MutationProcedure,
|
|
45
|
+
Observable,
|
|
46
|
+
Observer,
|
|
47
|
+
OnErrorFunction,
|
|
48
|
+
Overwrite,
|
|
49
|
+
PickFirstDefined,
|
|
50
|
+
Procedure,
|
|
51
|
+
ProcedureArgs,
|
|
52
|
+
ProcedureBuilder,
|
|
53
|
+
ProcedureCall,
|
|
54
|
+
ProcedureOptions,
|
|
55
|
+
ProcedureRecord,
|
|
56
|
+
ProcedureRouterRecord,
|
|
57
|
+
ProcedureType,
|
|
58
|
+
ProtectedIntersection,
|
|
59
|
+
QueryProcedure,
|
|
60
|
+
ResolveHTTPRequestOptionsContextFn,
|
|
61
|
+
ResponseChunk,
|
|
62
|
+
ResponseMeta,
|
|
63
|
+
ResponseMetaFn,
|
|
64
|
+
RootConfig,
|
|
65
|
+
Router,
|
|
66
|
+
RouterCaller,
|
|
67
|
+
Serialize,
|
|
68
|
+
SerializeObject,
|
|
69
|
+
Simplify,
|
|
70
|
+
SubscriptionProcedure,
|
|
71
|
+
TRPCClientIncomingMessage,
|
|
72
|
+
TRPCClientIncomingRequest,
|
|
73
|
+
TRPCClientOutgoingMessage,
|
|
74
|
+
TRPCClientOutgoingRequest,
|
|
75
|
+
TRPCErrorResponse,
|
|
76
|
+
TRPCErrorShape,
|
|
77
|
+
TRPCInferrable,
|
|
78
|
+
TRPCReconnectNotification,
|
|
79
|
+
TRPCRequest,
|
|
80
|
+
TRPCRequestInfo,
|
|
81
|
+
TRPCRequestMessage,
|
|
82
|
+
TRPCResponse,
|
|
83
|
+
TRPCResponseMessage,
|
|
84
|
+
TRPCResult,
|
|
85
|
+
TRPCResultMessage,
|
|
86
|
+
TRPCSubscriptionStopNotification,
|
|
87
|
+
TRPCSuccessResponse,
|
|
88
|
+
TRPC_ERROR_CODE_KEY,
|
|
89
|
+
TRPC_ERROR_CODE_NUMBER,
|
|
90
|
+
TeardownLogic,
|
|
91
|
+
Unsubscribable,
|
|
92
|
+
UnsubscribeFn,
|
|
93
|
+
Unwrap,
|
|
94
|
+
ValidateShape,
|
|
95
|
+
WithoutIndexSignature,
|
|
96
|
+
inferErrorShape,
|
|
97
|
+
inferHandlerInput,
|
|
98
|
+
inferObservableValue,
|
|
99
|
+
inferParser,
|
|
100
|
+
inferProcedureInput,
|
|
101
|
+
inferProcedureOutput,
|
|
102
|
+
inferProcedureParams,
|
|
103
|
+
inferRouterContext,
|
|
104
|
+
inferRouterError,
|
|
105
|
+
inferRouterInputs,
|
|
106
|
+
inferRouterMeta,
|
|
107
|
+
inferRouterOutputs,
|
|
108
|
+
inferTransformedProcedureOutput,
|
|
109
|
+
inferTransformedSubscriptionOutput,
|
|
110
|
+
} from '@trpc/core';
|
|
111
|
+
export {
|
|
112
|
+
TRPCError,
|
|
113
|
+
TRPC_ERROR_CODES_BY_KEY,
|
|
114
|
+
TRPC_ERROR_CODES_BY_NUMBER,
|
|
115
|
+
callProcedure,
|
|
116
|
+
createBuilder,
|
|
117
|
+
createFlatProxy,
|
|
118
|
+
createInputMiddleware,
|
|
119
|
+
createOutputMiddleware,
|
|
120
|
+
createRecursiveProxy,
|
|
121
|
+
createRouterFactory,
|
|
122
|
+
experimental_standaloneMiddleware,
|
|
123
|
+
getBatchStreamFormatter,
|
|
124
|
+
getCauseFromUnknown,
|
|
125
|
+
getErrorShape,
|
|
126
|
+
getHTTPStatusCode,
|
|
127
|
+
getHTTPStatusCodeFromError,
|
|
128
|
+
getJsonContentTypeInputs,
|
|
129
|
+
getTRPCErrorFromUnknown,
|
|
130
|
+
initTRPC,
|
|
131
|
+
isObject,
|
|
132
|
+
isObservable,
|
|
133
|
+
map,
|
|
134
|
+
mergeRouters,
|
|
135
|
+
middlewareMarker,
|
|
136
|
+
observable,
|
|
137
|
+
observableToPromise,
|
|
138
|
+
parseTRPCMessage,
|
|
139
|
+
procedureTypes,
|
|
140
|
+
resolveHTTPResponse,
|
|
141
|
+
share,
|
|
142
|
+
tap,
|
|
143
|
+
transformResult,
|
|
144
|
+
transformTRPCResponse,
|
|
145
|
+
unsetMarker,
|
|
146
|
+
} from '@trpc/core';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '../dist/unstableDontImportMe';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
module.exports = require('../dist/unstableDontImportMe');
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
export { getHTTPStatusCode, getHTTPStatusCodeFromError, } from '../../unstable-core-do-not-import';
|
|
2
|
-
export { resolveHTTPResponse } from '../../unstable-core-do-not-import';
|
|
3
|
-
export type { BaseHandlerOptions, HTTPBaseHandlerOptions, HTTPHeaders, HTTPRequest, HTTPResponse, OnErrorFunction, ProcedureCall, ResolveHTTPRequestOptionsContextFn, ResponseChunk, ResponseMeta, ResponseMetaFn, TRPCRequestInfo, } from '../../unstable-core-do-not-import';
|
|
4
|
-
export { getBatchStreamFormatter } from '../../unstable-core-do-not-import';
|
|
5
|
-
export type { BaseContentTypeHandler, BodyResult, } from '../../unstable-core-do-not-import';
|
|
6
|
-
export { getJsonContentTypeInputs } from '../../unstable-core-do-not-import';
|
|
7
|
-
//# sourceMappingURL=http.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"http.d.ts","sourceRoot":"","sources":["../../../src/@trpc/server/http.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,iBAAiB,EACjB,0BAA0B,GAC3B,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EAAE,mBAAmB,EAAE,MAAM,mCAAmC,CAAC;AACxE,YAAY,EACV,kBAAkB,EAClB,sBAAsB,EACtB,WAAW,EACX,WAAW,EACX,YAAY,EACZ,eAAe,EACf,aAAa,EACb,kCAAkC,EAClC,aAAa,EACb,YAAY,EACZ,cAAc,EACd,eAAe,GAChB,MAAM,mCAAmC,CAAC;AAE3C,OAAO,EAAE,uBAAuB,EAAE,MAAM,mCAAmC,CAAC;AAC5E,YAAY,EACV,sBAAsB,EACtB,UAAU,GACX,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EAAE,wBAAwB,EAAE,MAAM,mCAAmC,CAAC"}
|
|
@@ -1,69 +0,0 @@
|
|
|
1
|
-
export { TRPCError,
|
|
2
|
-
/**
|
|
3
|
-
* @deprecated use `experimental_trpcMiddleware` instead
|
|
4
|
-
*/
|
|
5
|
-
experimental_standaloneMiddleware, experimental_standaloneMiddleware as experimental_trpcMiddleware, initTRPC, callProcedure as callTRPCProcedure, getTRPCErrorFromUnknown, transformTRPCResponse, createFlatProxy as createTRPCFlatProxy, type inferProcedureInput, type inferProcedureOutput, type inferRouterError, type inferRouterInputs, type inferRouterOutputs, type inferRouterContext, type inferTransformedProcedureOutput, type inferTransformedSubscriptionOutput, type AnyProcedure as AnyTRPCProcedure, type AnyRouter as AnyTRPCRouter, type AnyMiddlewareFunction as AnyTRPCMiddlewareFunction, type CombinedDataTransformer as TRPCCombinedDataTransformer, type ProcedureType as TRPCProcedureType, type AnyMutationProcedure as AnyTRPCMutationProcedure, type AnyQueryProcedure as AnyTRPCQueryProcedure, type ProcedureRouterRecord as TRPCProcedureRouterRecord, type ProcedureArgs as TRPCProcedureArgs, type AnySubscriptionProcedure as AnyTRPCSubscriptionProcedure, } from '../../unstable-core-do-not-import';
|
|
6
|
-
export type {
|
|
7
|
-
/**
|
|
8
|
-
* @deprecated use `AnyTRPCProcedure` instead
|
|
9
|
-
*/
|
|
10
|
-
AnyProcedure,
|
|
11
|
-
/**
|
|
12
|
-
* @deprecated use `AnyTRPCRouter` instead
|
|
13
|
-
*/
|
|
14
|
-
AnyRouter,
|
|
15
|
-
/**
|
|
16
|
-
* @deprecated use `AnyTRPCMiddlewareFunction` instead
|
|
17
|
-
*/
|
|
18
|
-
AnyMiddlewareFunction,
|
|
19
|
-
/**
|
|
20
|
-
* @deprecated use `TRPCCombinedDataTransformer` instead
|
|
21
|
-
*/
|
|
22
|
-
CombinedDataTransformer,
|
|
23
|
-
/**
|
|
24
|
-
* @deprecated This is a utility type will be removed in v12
|
|
25
|
-
*/
|
|
26
|
-
Dict,
|
|
27
|
-
/**
|
|
28
|
-
* @deprecated This is a utility type will be removed in v12
|
|
29
|
-
*/
|
|
30
|
-
DeepPartial,
|
|
31
|
-
/**
|
|
32
|
-
* @deprecated use `TRPCProcedureType` instead
|
|
33
|
-
*/
|
|
34
|
-
ProcedureType,
|
|
35
|
-
/**
|
|
36
|
-
* @deprecated use `AnyTRPCMutationProcedure` instead
|
|
37
|
-
*/
|
|
38
|
-
AnyMutationProcedure,
|
|
39
|
-
/**
|
|
40
|
-
* @deprecated use `AnyTRPCQueryProcedure` instead
|
|
41
|
-
*/
|
|
42
|
-
AnyQueryProcedure,
|
|
43
|
-
/**
|
|
44
|
-
* @deprecated use `TRPCProcedureRouterRecord` instead
|
|
45
|
-
*/
|
|
46
|
-
ProcedureRouterRecord,
|
|
47
|
-
/**
|
|
48
|
-
* @deprecated use `TRPCProcedureArgs` instead
|
|
49
|
-
*/
|
|
50
|
-
ProcedureArgs,
|
|
51
|
-
/**
|
|
52
|
-
* @deprecated use `AnyTRPCSubscriptionProcedure` instead
|
|
53
|
-
*/
|
|
54
|
-
AnySubscriptionProcedure, } from '../../unstable-core-do-not-import';
|
|
55
|
-
export {
|
|
56
|
-
/**
|
|
57
|
-
* @deprecated use `getTRPCErrorShape` instead
|
|
58
|
-
*/
|
|
59
|
-
getErrorShape,
|
|
60
|
-
/**
|
|
61
|
-
* @deprecated use `callTRPCProcedure` instead
|
|
62
|
-
*/
|
|
63
|
-
callProcedure, } from '../../unstable-core-do-not-import';
|
|
64
|
-
/**
|
|
65
|
-
* @deprecated
|
|
66
|
-
* Use `Awaited<ReturnType<typeof myFunction>>` instead
|
|
67
|
-
*/
|
|
68
|
-
export type inferAsyncReturnType<TFunction extends (...args: any[]) => any> = Awaited<ReturnType<TFunction>>;
|
|
69
|
-
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/@trpc/server/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS;AACT;;GAEG;AACH,iCAAiC,EACjC,iCAAiC,IAAI,2BAA2B,EAChE,QAAQ,EAER,aAAa,IAAI,iBAAiB,EAClC,uBAAuB,EACvB,qBAAqB,EACrB,eAAe,IAAI,mBAAmB,EACtC,KAAK,mBAAmB,EACxB,KAAK,oBAAoB,EACzB,KAAK,gBAAgB,EACrB,KAAK,iBAAiB,EACtB,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,EACvB,KAAK,+BAA+B,EACpC,KAAK,kCAAkC,EACvC,KAAK,YAAY,IAAI,gBAAgB,EACrC,KAAK,SAAS,IAAI,aAAa,EAC/B,KAAK,qBAAqB,IAAI,yBAAyB,EACvD,KAAK,uBAAuB,IAAI,2BAA2B,EAC3D,KAAK,aAAa,IAAI,iBAAiB,EACvC,KAAK,oBAAoB,IAAI,wBAAwB,EACrD,KAAK,iBAAiB,IAAI,qBAAqB,EAC/C,KAAK,qBAAqB,IAAI,yBAAyB,EACvD,KAAK,aAAa,IAAI,iBAAiB,EACvC,KAAK,wBAAwB,IAAI,4BAA4B,GAC9D,MAAM,mCAAmC,CAAC;AAE3C,YAAY;AACV;;GAEG;AACH,YAAY;AACZ;;GAEG;AACH,SAAS;AACT;;GAEG;AACH,qBAAqB;AACrB;;GAEG;AACH,uBAAuB;AAEvB;;GAEG;AACH,IAAI;AAEJ;;GAEG;AACH,WAAW;AACX;;GAEG;AACH,aAAa;AACb;;GAEG;AACH,oBAAoB;AAEpB;;GAEG;AACH,iBAAiB;AACjB;;GAEG;AACH,qBAAqB;AACrB;;GAEG;AACH,aAAa;AACb;;GAEG;AACH,wBAAwB,GACzB,MAAM,mCAAmC,CAAC;AAE3C,OAAO;AACL;;GAEG;AACH,aAAa;AAEb;;GAEG;AACH,aAAa,GACd,MAAM,mCAAmC,CAAC;AAE3C;;;GAGG;AACH,MAAM,MAAM,oBAAoB,CAAC,SAAS,SAAS,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,GAAG,IACxE,OAAO,CAAC,UAAU,CAAC,SAAS,CAAC,CAAC,CAAC"}
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
export type { JSONRPC2, TRPCClientIncomingMessage, TRPCClientIncomingRequest, TRPCClientOutgoingMessage, TRPCClientOutgoingRequest, TRPCErrorResponse, TRPCErrorShape, TRPCReconnectNotification, TRPCRequest, TRPCRequestMessage, TRPCResponse, TRPCResponseMessage, TRPCResult, TRPCResultMessage, TRPCSubscriptionStopNotification, TRPCSuccessResponse, TRPC_ERROR_CODE_KEY, TRPC_ERROR_CODE_NUMBER, } from '../../unstable-core-do-not-import';
|
|
2
|
-
export { TRPC_ERROR_CODES_BY_KEY, TRPC_ERROR_CODES_BY_NUMBER, parseTRPCMessage, } from '../../unstable-core-do-not-import';
|
|
3
|
-
//# sourceMappingURL=rpc.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"rpc.d.ts","sourceRoot":"","sources":["../../../src/@trpc/server/rpc.ts"],"names":[],"mappings":"AACA,YAAY,EACV,QAAQ,EACR,yBAAyB,EACzB,yBAAyB,EACzB,yBAAyB,EACzB,yBAAyB,EACzB,iBAAiB,EACjB,cAAc,EACd,yBAAyB,EACzB,WAAW,EACX,kBAAkB,EAClB,YAAY,EACZ,mBAAmB,EACnB,UAAU,EACV,iBAAiB,EACjB,gCAAgC,EAChC,mBAAmB,EACnB,mBAAmB,EACnB,sBAAsB,GACvB,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EACL,uBAAuB,EACvB,0BAA0B,EAC1B,gBAAgB,GACjB,MAAM,mCAAmC,CAAC"}
|