When I attempt to do this with idb, I get the typescript error:
No overload matches this call.
Overload 1 of 2, '(storeNames: string, mode?: "readonly" | undefined, options?: IDBTransactionOptions | undefined): IDBPTransaction<unknown, [string], "readonly">', gave the following error.
Argument of type 'TypedDOMStringList<string>' is not assignable to parameter of type 'string'.
Overload 2 of 2, '(storeNames: string[], mode?: "readonly" | undefined, options?: IDBTransactionOptions | undefined): IDBPTransaction<unknown, string[], "readonly">', gave the following error.
Argument of type 'TypedDOMStringList<string>' is not assignable to parameter of type 'string[]'.
Type 'TypedDOMStringList<string>' is missing the following properties from type 'string[]': pop, push, concat, join, and 26 more.
I'm fairly certain we can fix this by adding a third overload to transaction (happy to write that PR if you want), but wanted to check if this was intentional before throwing up a fix!
Hi,
I am trying to open a transaction that has access to all stores. MDN recommends doing this by:
(https://developer.mozilla.org/en-US/docs/Web/API/IDBDatabase/transaction)
When I attempt to do this with idb, I get the typescript error:
I'm fairly certain we can fix this by adding a third overload to transaction (happy to write that PR if you want), but wanted to check if this was intentional before throwing up a fix!
Thanks, Tomas