question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Typescript issue with result of a promised query

See original GitHub issue
Screen Shot 2022-10-19 at 00 47 27 Screen Shot 2022-10-19 at 00 47 54

Is there a way to fix this issue dynamically? Or am I forced to cast rows to any[] type?

Issue Analytics

  • State:closed
  • Created a year ago
  • Reactions:1
  • Comments:12 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
sidorarescommented, Oct 27, 2022

But I would appreciate it if this was better documented.

Agreed, we can improve on that

0reactions
ChezCodercommented, Oct 27, 2022

Ok, after reading your answer, I guess it sort of makes sense.

But I would appreciate it if this was better documented.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Issue with 'Promise<QueryResult<any>>' for TypeScript + ...
Hi r/typescript , I'm creating an API with TypeScript and Postgres but I'm having an issue with my 'response' on line 6. I'm...
Read more >
Typescript error in async function: 'Promise<string[]' provides ...
I have working code but need to refactor the function to make it reusable. I'm not super familiar with typescript or client.query and...
Read more >
Typescript query result type can be improved #266 - GitHub
Now I notice that it's just the pg query result. So the only possible improvement would be to change it from any to...
Read more >
Using JavaScript Promises - AWS Documentation
The AWS.Request.promise method provides a way to call a service operation and manage asynchronous flow instead of using callbacks. In Node.js and browser ......
Read more >
How to use promises - Learn web development | MDN
Promises are the foundation of asynchronous programming in modern JavaScript. A promise is an object returned by an asynchronous function, ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found