[ 源代码: node-thenify ]
软件包:node-thenify(3.3.1-4)
Promisify a callback-based function
Some features of this module:
- Preserves function names - Uses a native promise implementation - Converts multiple arguments from the callback into an Array, also support change the behavior by options.multiArgs - Resulting function never deoptimizes - Supports both callback and promise styleAn added benefit is that thrown errors in that async function will be caught by the promise!
Node.js is an event-based server-side JavaScript engine.
