From 372eb0f67f2b1aec883784772a0b1615fc23e267 Mon Sep 17 00:00:00 2001 From: tommyZZM Date: Wed, 2 Dec 2015 16:29:03 +0800 Subject: [PATCH] Update style.md --- docs/style.md | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/docs/style.md b/docs/style.md index 28c4378..6f51794 100644 --- a/docs/style.md +++ b/docs/style.md @@ -260,12 +260,11 @@ const nodes = Array.from(foo); }); // good -[1, 2, 3].map(x => { - return x * x; -}); +[1, 2, 3].map(x => x * x); -// with more than one argument +// with more argument and code [1, 2, 3].map((x,i) => { + console.log(x); return x * i; }); ```