From 727633492a9122bb3ab7418ae4bb9b10de0878c9 Mon Sep 17 00:00:00 2001 From: Dieter Luypaert Date: Fri, 26 Jun 2020 10:31:57 +0200 Subject: [PATCH] Docs: add `no-magic-numbers` array destructuring example --- docs/rules/no-magic-numbers.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/docs/rules/no-magic-numbers.md b/docs/rules/no-magic-numbers.md index d0d6cdff96d8..92b8667a8f2d 100644 --- a/docs/rules/no-magic-numbers.md +++ b/docs/rules/no-magic-numbers.md @@ -142,6 +142,11 @@ const { tax = 0.25 } = accountancy; function mapParallel(concurrency = 3) { /***/ } ``` +```js +let head; +[head = 100] = [] +``` + ### enforceConst A boolean to specify if we should check for the const keyword in variable declaration of numbers. `false` by default.