Difference between Array(n) and Array(n).fill?

前端 未结 0 562
遇见更好的自我
遇见更好的自我 2021-02-13 00:58

I\'ve noticed that if I do:

Array(n).map(() => console.log(\'test\'))

I get nothing printed.

However if I do:

Array(         


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题