But be mindful to use res only after the promise resolved, if you depend on that value, call the next function from inside the .then like this:var res;p1.then(function(result){ var abc = NextFunction(result);}); 这篇关于如何使用没有 .then 函数的 node.js 从 promise 中获取值的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!
10-28 01:09