rockset / rockset-js

Apache License 2.0
12 stars 6 forks source link

Add generics to query responses #73

Open raheelrjunaid opened 1 year ago

raheelrjunaid commented 1 year ago

I appears a wrapper around the QueriesApi is required to achieve result typing on queries (as denoted in the examples.ts). I propose adding typing to the rocksetClient.queries.query definition in

https://github.com/rockset/rockset-js/blob/143cb5b0436b84d977f95cc5d2aea03c7c249922/packages/client/src/codegen/api.ts#L3809-L3814

The same goes for pagination: (getQueryResults)

https://github.com/rockset/rockset-js/blob/143cb5b0436b84d977f95cc5d2aea03c7c249922/packages/client/src/codegen/api.ts#L3640-L3644

raheelrjunaid commented 1 year ago

I can work on this, but I'm looking to understand any missing context before beginning development.