Closed tbeseda closed 2 years ago
@camjackson can you take a look at this? Let me know if there's a more TypeScript-y way to make this update.
@tbeseda I left a couple of suggestions for more specific types. As for the intersection I think that's fine. I don't know of a better way to say "this object maps all the keys from Tables
, and it also has these other properties".
I used an intersection type to add top level methods and attributes to
type ArcDB
.I also changed the return type for the
put
method toRecord<string, any>
since the Arc client returns the new/updated document. should it beItem
?editor screenshot
![image](https://user-images.githubusercontent.com/15697/174136639-fc6be6b7-fbd3-44da-9cac-b63c03bce51b.png)