From 7ad58a783303aaffcb6962f7df401caa024f0489 Mon Sep 17 00:00:00 2001 From: Fredrick Mgbeoma Date: Tue, 5 Sep 2017 00:21:04 +0100 Subject: [PATCH] Update article.md --- 1-js/05-data-types/09-destructuring-assignment/article.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/1-js/05-data-types/09-destructuring-assignment/article.md b/1-js/05-data-types/09-destructuring-assignment/article.md index 1eb37ebe..df553aeb 100644 --- a/1-js/05-data-types/09-destructuring-assignment/article.md +++ b/1-js/05-data-types/09-destructuring-assignment/article.md @@ -308,7 +308,7 @@ let options = { let {title, ...rest} = options; */!* -// now title="Menu", rest={height: 200, widht: 100} +// now title="Menu", rest={height: 200, width: 100} alert(rest.height); // 200 alert(rest.width); // 100 ``` @@ -389,7 +389,7 @@ The whole `options` object except `extra` that was not mentioned, is assigned to Finally, we have `width`, `height`, `item1`, `item2` and `title` from the default value. -That often happens with destructuring assignments. We have a complex object with may properties and want extract only what we need. +That often happens with destructuring assignments. We have a complex object with many properties and want to extract only what we need. Even like this: ```js