-
Notifications
You must be signed in to change notification settings - Fork 152
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add multi-key get
typings overload
#359
Add multi-key get
typings overload
#359
Conversation
get
typings overload
@trevor-scheer - can you get the linting fixed on these? Most likely you can do a |
@jaredwray it did fix some things but also spit out these errors (unrelated to my changes)
|
@trevor-scheer - thanks go ahead and roll back the changes and we can fix them on our side then will bring in your type fix. |
50d997a
to
719adb9
Compare
Ok. I get a ton of errors when I run Reverted the original lint, this time just committed changes to the file I edited. |
Looks like xo version to test the project just download the latest and then do the following:
|
Codecov Report
@@ Coverage Diff @@
## main #359 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 18 18
Lines 1113 1113
=========================================
Hits 1113 1113 Continue to review full report at Codecov.
|
@trevor-scheer - this will be released in the next week or so with other updates being tested |
Thanks! |
Keyv
supports the use ofget
in an overloaded manner. Pass a single key, get a single result; pass an array of keys, get an array of results.The current typings as they're written return a singular
Value
in both cases. By overloading this method, we can get the correct return typestring -> Value | undefined
,string[] -> (Value | undefined)[]
.