You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi! Lovely library, thank you for sharing it with the world!
The documentation for .set states:
.set(key, value, options?)
Set an item. Returns the instance.
(Emphasis mine.) This seems to be wrong – .set doesn't actually return anything. It would be rather handy if it returned the value though, it'd allow for things like:
constthing=lru.get(key)??lru.set(key,getThing())
Returning the instance would work too I suppose, it'd be a bit awkward but still:
Hi! Lovely library, thank you for sharing it with the world!
The documentation for
.set
states:(Emphasis mine.) This seems to be wrong –
.set
doesn't actually return anything. It would be rather handy if it returned thevalue
though, it'd allow for things like:Returning the instance would work too I suppose, it'd be a bit awkward but still:
Either way,
.set
doesn't actually return anything so the docs seem to be wrong.The text was updated successfully, but these errors were encountered: