Feature request: promise API?
See original GitHub issueWith async/await it would be useful it winston exposed a promise API (this could be done in a backwards compatible way).
const doSomething = async () => {
// this doesn't block
logger.error('some error', new Error('foo'))
// this blocks
await logger.error('some error', new Error('foo'))
// get sentry ID
const sentryErrorId = await logger.error('some error', new Error('foo'))
}
doSomething()
Issue Analytics
- State:
- Created 6 years ago
- Reactions:47
- Comments:9 (3 by maintainers)
Top Results From Across the Web
'request' with Promise - GitHub
The simplified HTTP request client 'request' with Promise support. Powered by Bluebird. - GitHub - request/request-promise: The simplified HTTP request ...
Read more >How to Make API Requests with Request-Promise in Node.js
... of this tutorial for links to prerequisites and related tutorials: https://heynode.com/tutorial/how-make- api -requests- request - promise...
Read more >Top 5 request-promise-native Code Examples - Snyk
To help you get started, we've selected a few request-promise-native examples, based on popular ways it is used in public projects.
Read more >README.md - UNPKG
API in Detail Consider Request-Promise being: - A Request object - With an ... cancellation feature](http://bluebirdjs.com/docs/api/cancellation.html).
Read more >request-promise-native | Yarn - Package Manager
Native ES6+ promises may have fewer features than Bluebird promises do. In particular, the .finally(...) method was not included until Node v10. Installation....
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
It’s still a valid feature request – if more folks 👍 we’ll consider it. Just wanted to be clear that the lack of it is not causing any problems nor the source of any defects.
+1