Код: Выделить всё
.then( Promise.all )
< /code>
Работа? И почему < /p>
.then( Promise.all.bind( Promise ) )
< /code>
Работа? < /p>
Promise.resolve( [ Promise.resolve( 1 ), Promise.resolve( 2 ) ] ).then( Promise.all ).then( arr => console.log( arr ) )
< /code>
unaught (в обещании) TypeError: получатель обещания. Все вызов не является не нулевым объектом < /p>
Promise.resolve( [ Promise.resolve( 1 ), Promise.resolve( 2 ) ] ).then( Promise.all.bind( Promise ) ).then( arr => console.log( arr ) )
Подробнее здесь: https://stackoverflow.com/questions/794 ... javascript