From 99249cb3b8756be8ce1319bf635ae5580a4e94b8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20Allienne?= Date: Tue, 23 Jan 2018 21:10:56 +0100 Subject: [PATCH] solution: Add solution for bases Close #3 --- exercises/bases/exo.js | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/exercises/bases/exo.js b/exercises/bases/exo.js index b951523..dc7151a 100644 --- a/exercises/bases/exo.js +++ b/exercises/bases/exo.js @@ -1,8 +1,6 @@ - -function testDestructuring(arrayIndex, objectName, restLength){ - // Vous ne devez rien changer ici, juste utiliser les mêmes noms de variable - return arrayIndex + objectName + restLength.length; +function testDestructuring([, arrayIndex,], {name: objectName} = {name: 'toto'}, ...restLength) { + // Vous ne devez rien changer ici, juste utiliser les mêmes noms de variable + return arrayIndex + objectName + restLength.length; } - module.exports = {testDestructuring};