V11 Roadmap Ideas #229
Replies: 15 comments 27 replies
-
Since it's a major version, maybe think about standardizing the POST/GET method signatures with a single object parameter? |
Beta Was this translation helpful? Give feedback.
-
Yes Fetch! |
Beta Was this translation helpful? Give feedback.
-
looks promising ! 👏 regarding the axios-like fetch implementation, a few have been made already, I'm not sure if they have 100% feature parity with axios tho but if not using them directly I guess this could serve as inspiration:
there are probably more that I don't know of |
Beta Was this translation helpful? Give feedback.
-
just an idea: What about normalized cache (optional)? |
Beta Was this translation helpful? Give feedback.
-
You can check progress in this branch |
Beta Was this translation helpful? Give feedback.
-
Would love to see "go to definition" working for the aliases. So I could go from the client to my api definition. This would probably mean that the api needs to be defined as an object rather than an array. |
Beta Was this translation helpful? Give feedback.
-
If you want to test the new type provider, you can play with it with the rc-0 release: https://github.com/ecyrbe/zodios/releases/tag/v11.0.0-rc.0 available on npm To install a beta version, you need to install it explicitly : npm i @zodios/core@11.0.0-rc.0 |
Beta Was this translation helpful? Give feedback.
-
A quick update for everyone, beta packages are available for :
What's missing is react/solid and express/openapi packages for v11. Everything is in a monorepo now. So the old repositories will be removed 3 month after release. |
Beta Was this translation helpful? Give feedback.
-
Feature requestAs @zodios/react will be independent from { modifyQueryKey: (queryKeyByZodiosReact: QueryKey) => QueryKey } My usecase is to { modifyQueryKey: (queryKeyByZodiosReact: QueryKey) => [getAuthToken(), ...queryKeyByZodiosReact] } so a user won't see data other user's data after switching to a different account. This is the suggest way to queryKey by SWR. |
Beta Was this translation helpful? Give feedback.
-
I've noticed that a server response is not parsed by Zod, only typed. Or maybe it's configured in a way to preserve unknown keys. // ^ response: z.object({name: z.string()})
// ...
const result = {name: "foo", junk: "bar"}
return res.status(200).json(result) // will ensure a correct TS type but response will contain both `name` and `junk` keys One thing that might be useful for is to drop extra fields coming from a database. It's not the most effective way of doing that, but it can be quite beneficial while developing and even later in dev mode – to be sure your code is correctly typed. So an option to enable response parsing/validation is worth considering IMO. |
Beta Was this translation helpful? Give feedback.
-
I would love to see Zodios Client be augmented to support better customization. Right now, Zodios Client seems very brittle when trying to implement any logic at all that is non-standard. Some of this brittleness is due to Axios, some is due to Zod, some is due to TypeScript, and some is due to the relatively weak way that Zodios Client supports middleware. Any plans to improve this for v11? UPDATE: clarified that I'm referring to Zodios Client above, although to be honest, I don't know what the difference is between Zodios Client and Zodios Server, since I haven't used server. |
Beta Was this translation helpful? Give feedback.
-
hey @ecyrbe is there any timeline for releasing v11? maybe it's worth releasing an update of what is left for that release. maybe I can assist or other ppl as well |
Beta Was this translation helpful? Give feedback.
-
Hey! I am working on a Zodios adapter for AdonisJS 6. just wanted to ask two questions:
happy to contribute in any forms ( thinking especially about vue hooks ), but I think for the time being, it's going to be quite complicated as i guess there's a lot moving parts before the official release of V11. but let me know if there's anything I can do before that |
Beta Was this translation helpful? Give feedback.
-
Add more Options for OpenApi-Documentation, e.g. extend Zod with https://github.com/asteasolutions/zod-to-openapi or https://github.com/anatine/zod-plugins |
Beta Was this translation helpful? Give feedback.
-
☝️ relevant for anyone migrating v10->v11 |
Beta Was this translation helpful? Give feedback.
-
Here is a discussion to share ideas for zodios V11.
As a reminder, Zodios scope is REST APIs, so we will not consider notifications, real time communication, RPC, Next RSC or Remix loader/actions type safety features (these would be completely distinct projects)
Zod
/Io-Ts
Validation :input
andoutput
type inferrence@zodios/axios
and keep@zodios/core
with only common types and helpers@zodios/axios-plugins
@zodios/fetch
@zodios/fetch-plugins
client.deleteUser(undefined, { params: { id: 1 } })
but simplyclient.deleteUser({ params: { id: 1 } })
@zodios/testing
package that work for both axios/fetch clientsIn the works (not really tied to v11) :
@zodios/fastify
alternative to@zodios/express
@zodios/vue
add vue adapter for@tanstack/vue-query
Progress implementation in v11 branch
Beta Was this translation helpful? Give feedback.
All reactions