From f60d2298ca9f0d940e2900dec47fa8213d8de33c Mon Sep 17 00:00:00 2001 From: cky <576779975@qq.com> Date: Thu, 12 Apr 2018 20:02:56 +0800 Subject: [PATCH] delete: collapse组件不需要的代码 --- src/components/collapse/collapse.vue | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/src/components/collapse/collapse.vue b/src/components/collapse/collapse.vue index 4046319..74e81a3 100644 --- a/src/components/collapse/collapse.vue +++ b/src/components/collapse/collapse.vue @@ -36,15 +36,8 @@ this.$children.forEach((child, index) => { const name = child.name || index.toString(); - let isActive = false; - if (self.accordion) { - isActive = activeKey === name; - } else { - isActive = activeKey.indexOf(name) > -1; - } - - child.isActive = isActive; + child.isActive = activeKey.indexOf(name) > -1; child.index = index; }); }, -- libgit2 0.21.4