@trpc-panel/core 1.0.2 → 1.0.3
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/README.md +13 -3
- package/lib/index.js +19060 -365
- package/lib/index.mjs +19027 -362
- package/lib/react-app/bundle.js +759 -81
- package/lib/react-app/index.css +266 -54
- package/lib/scripts/build-react.d.ts +1 -0
- package/lib/src/meta.d.ts +1 -5
- package/lib/src/parse/__tests__/utils/router.d.ts +13 -53
- package/lib/src/parse/input-mappers/zod/parsers/parseZodArrayDef.d.ts +13 -2
- package/lib/src/parse/input-mappers/zod/parsers/parseZodBigIntDef.d.ts +7 -3
- package/lib/src/parse/input-mappers/zod/parsers/parseZodBooleanFieldDef.d.ts +6 -2
- package/lib/src/parse/input-mappers/zod/parsers/parseZodBrandedDef.d.ts +13 -2
- package/lib/src/parse/input-mappers/zod/parsers/parseZodDefaultDef.d.ts +14 -2
- package/lib/src/parse/input-mappers/zod/parsers/parseZodDiscriminatedUnionDef.d.ts +7 -14
- package/lib/src/parse/input-mappers/zod/parsers/parseZodEffectsDef.d.ts +27 -2
- package/lib/src/parse/input-mappers/zod/parsers/parseZodEnumDef.d.ts +8 -2
- package/lib/src/parse/input-mappers/zod/parsers/parseZodLiteralDef.d.ts +8 -2
- package/lib/src/parse/input-mappers/zod/parsers/parseZodNullDef.d.ts +7 -3
- package/lib/src/parse/input-mappers/zod/parsers/parseZodNullableDef.d.ts +13 -2
- package/lib/src/parse/input-mappers/zod/parsers/parseZodNumberDef.d.ts +6 -2
- package/lib/src/parse/input-mappers/zod/parsers/parseZodObjectDef.d.ts +14 -2
- package/lib/src/parse/input-mappers/zod/parsers/parseZodOptionalDef.d.ts +14 -3
- package/lib/src/parse/input-mappers/zod/parsers/parseZodPromiseDef.d.ts +13 -2
- package/lib/src/parse/input-mappers/zod/parsers/parseZodStringDef.d.ts +6 -2
- package/lib/src/parse/input-mappers/zod/parsers/parseZodUndefinedDef.d.ts +7 -3
- package/lib/src/parse/input-mappers/zod/parsers/parseZodVoidDef.d.ts +7 -3
- package/lib/src/parse/input-mappers/zod/selector.d.ts +2 -1
- package/lib/src/parse/input-mappers/zod/zod-types.d.ts +5 -3
- package/lib/src/parse/parseNodeTypes.d.ts +2 -2
- package/lib/src/parse/routerType.d.ts +56 -400
- package/package.json +13 -18
package/README.md
CHANGED
|
@@ -19,6 +19,7 @@ Check out our [test app](https://app.trpcpanel.io)
|
|
|
19
19
|
- 🐦 Supports nested routers, and nested input objects. The structure of the UI maps one-to-one to your API's routers and procedures.
|
|
20
20
|
- 🧭 SideNav and VSCode-like procedure / router search to quickly find what you're looking for
|
|
21
21
|
- ✨ [Transform](#data-transformers) data with built in `superjson` support.
|
|
22
|
+
- 🔧 **Zod v4** support with full compatibility for all Zod types
|
|
22
23
|
|
|
23
24
|
## Quick Start
|
|
24
25
|
|
|
@@ -132,11 +133,18 @@ app.use("/panel", (_, res) => {
|
|
|
132
133
|
|
|
133
134
|
`trpc-panel` welcomes and encourages open source contributions. Please see our [contributing](./CONTRIBUTING.md) guide for information on how to develop locally.
|
|
134
135
|
|
|
136
|
+
## Requirements
|
|
137
|
+
|
|
138
|
+
- **tRPC**: v10 or v11
|
|
139
|
+
- **Zod**: v4.x (^4.2.1 recommended)
|
|
140
|
+
|
|
141
|
+
> **Note**: This version requires Zod v4. If you're using Zod v3, please use an earlier version of trpc-panel.
|
|
142
|
+
|
|
135
143
|
## Limitations
|
|
136
144
|
|
|
137
|
-
Currently, tRPC panel
|
|
145
|
+
Currently, tRPC panel only works with Zod input schemas. With its current design it would be feasible to easily add support for other input types as well.
|
|
138
146
|
|
|
139
|
-
There are no plans to support v9 or other previous tRPC versions.
|
|
147
|
+
There are no plans to support tRPC v9 or other previous tRPC versions.
|
|
140
148
|
|
|
141
149
|
### Supported zod types
|
|
142
150
|
|
|
@@ -157,13 +165,15 @@ The following are supported
|
|
|
157
165
|
- Number
|
|
158
166
|
- Object
|
|
159
167
|
- Optional
|
|
168
|
+
- Pipe (transform/preprocess)
|
|
160
169
|
- Promise
|
|
161
170
|
- String
|
|
162
171
|
- Undefined
|
|
172
|
+
- Void
|
|
163
173
|
|
|
164
174
|
We would like to add the following types:
|
|
165
175
|
|
|
166
|
-
- Union
|
|
176
|
+
- Union (non-discriminated)
|
|
167
177
|
- Tuple
|
|
168
178
|
- Record
|
|
169
179
|
- Never
|