Is there a good way to get redis command option types? #2609
willscripted
started this conversation in
General
Replies: 1 comment 1 reply
-
You can use the type XAddOptions = Parameters<typeof client['xAdd'])[3]; this is not optimal, and will improve in v5 :) |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Would love it if command option types were exported. I find myself adding option types to the top of any file that calls redis.
For example, a recent file header adds this:
Is there a better way of doing this? My go-to here is using
@types
to install the missing types, but @types/redis has the warning "This is a stub types definition. redis provides its own type definitions, so you do not need this installed." And rightly so, they seem like they exist, they just aren't exported to the public.Has anyone found a good way of handling this?
Beta Was this translation helpful? Give feedback.
All reactions