for of loop querySelectorAll

前端 未结 9 831
忘了有多久
忘了有多久 2020-12-11 02:29

Mozilla states that \"for of loops will loop over NodeList objects correctly\". (source: https://developer.mozilla.org/en-US/docs/Web/API/NodeList) However, this doesn\'t wo

9条回答
  •  死守一世寂寞
    2020-12-11 02:50

    I had this problem. Turns out mine was caused by calling Promise.all() with parameters instead of an array. For example:

    Before: Promise.all(p1, p2)

    After: Promise.all([p1, p2])

    Hope this helps someone.

提交回复
热议问题