diff --git a/README.md b/README.md index da44e3841..2da6dbc3e 100644 --- a/README.md +++ b/README.md @@ -4118,6 +4118,7 @@ Use `Math.max()` combined with the spread operator (`...`) to get the maximum va + const max = (...arr) => Math.max(...[].concat(...arr); ``` diff --git a/docs/index.html b/docs/index.html index e1f764ce6..80634f562 100644 --- a/docs/index.html +++ b/docs/index.html @@ -1839,6 +1839,7 @@ Use Number() to check if the coercion holds.

+ const max = (...arr) => Math.max(...[].concat(...arr);
max([10, 1, 5]); // 10
diff --git a/snippets/max.md b/snippets/max.md
index 828d3ca6f..ca84a90f8 100644
--- a/snippets/max.md
+++ b/snippets/max.md
@@ -23,6 +23,7 @@ Use `Math.max()` combined with the spread operator (`...`) to get the maximum va
 
 
 
+
 const max = (...arr) => Math.max(...[].concat(...arr);
 ```