Skip to content

Commit

Permalink
use default any on KeyvCache exported function; bump deps
Browse files Browse the repository at this point in the history
  • Loading branch information
nwaughachukwuma committed May 19, 2023
1 parent 0dc45dc commit c0953ba
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,9 @@ export function makeResponse(result: any, ttl: number) {
});
}

export default function KeyvCache<T>(options?: CacheOptions): CacheHandlers<T> {
export default function KeyvCache<T = any>(
options?: CacheOptions
): CacheHandlers<T> {
return !isBrowser() || !window.caches || !window.caches.open
? new InMemoryCache<T>()
: new BrowserCache<T>(options);
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "keyv-cache",
"version": "3.0.1",
"version": "3.0.2",
"description": "~1kb key/value store wrapper for the browser cache-api, with zero-dependency",
"repository": "[email protected]:nwaughachukwuma/keyv-cache.git",
"author": "Chukwuma Nwaugha <[email protected]>",
Expand Down

0 comments on commit c0953ba

Please sign in to comment.