1
0
mirror of https://github.com/ruanyf/es6tutorial.git synced 2025-05-29 05:42:20 +00:00

Fix 替代数组->替代函数

扩展运算符应该是可以替代函数的 apply 方法。
This commit is contained in:
gongpeione 2018-01-03 00:36:05 +08:00 committed by GitHub
parent b9e9f4e5b4
commit 90392b6e40
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -58,7 +58,7 @@ const arr = [
// [1] // [1]
``` ```
### 替代数的 apply 方法 ### 替代数的 apply 方法
由于扩展运算符可以展开数组,所以不再需要`apply`方法,将数组转为函数的参数了。 由于扩展运算符可以展开数组,所以不再需要`apply`方法,将数组转为函数的参数了。