回答編集履歴
3
a
test
CHANGED
@@ -12,6 +12,8 @@
|
|
12
12
|
|
13
13
|
console.log(...numbers); // 1, 2, 3
|
14
14
|
|
15
|
+
```
|
16
|
+
|
15
17
|
|
16
18
|
|
17
19
|
#使用例2
|
2
a
test
CHANGED
@@ -6,6 +6,16 @@
|
|
6
6
|
|
7
7
|
#使用例1
|
8
8
|
|
9
|
+
```
|
10
|
+
|
11
|
+
const numbers = [1, 2, 3];
|
12
|
+
|
13
|
+
console.log(...numbers); // 1, 2, 3
|
14
|
+
|
15
|
+
|
16
|
+
|
17
|
+
#使用例2
|
18
|
+
|
9
19
|
![イメージ説明](d2d102b3ae90423fb7da027d7e07c071.png)
|
10
20
|
|
11
21
|
この質問ページ上でChrome Canaryのconsoleで上記のように実行すると、こうなります。
|
1
しようれい
test
CHANGED
@@ -1,3 +1,11 @@
|
|
1
1
|
その文脈での「...」は日本語ではスプレッド演算子と言われるものになります。
|
2
2
|
|
3
3
|
[https://developer.mozilla.org/ja/docs/Web/JavaScript/Reference/Operators/Spread_operator](https://developer.mozilla.org/ja/docs/Web/JavaScript/Reference/Operators/Spread_operator)
|
4
|
+
|
5
|
+
|
6
|
+
|
7
|
+
#使用例1
|
8
|
+
|
9
|
+
![イメージ説明](d2d102b3ae90423fb7da027d7e07c071.png)
|
10
|
+
|
11
|
+
この質問ページ上でChrome Canaryのconsoleで上記のように実行すると、こうなります。
|