Skip to content

Commit ee62a28

Browse files
committed
style: according eslint
1 parent 0172a29 commit ee62a28

File tree

1 file changed

+14
-14
lines changed

1 file changed

+14
-14
lines changed

src/vue-2-breadcrumbs.js

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,26 @@
11
export default {
2-
install (Vue) {
2+
install(Vue) {
33
Object.defineProperties(Vue.prototype, {
44
$breadcrumbs: {
5-
get () {
5+
get() {
66
return this.$route.matched.map(r => {
7-
let path = ''
8-
let route = r
7+
let path = '';
8+
let route = r;
99

10-
Object.keys(this.$route.params).map(e => {
11-
path = route.path.replace(':' + e, this.$route.params[e])
12-
}, this)
13-
route.path = path
14-
return route
15-
}, this)
10+
Object.keys(this.$route.params).forEach(e => {
11+
path = route.path.replace(':' + e, this.$route.params[e]);
12+
}, this);
13+
route.path = path;
14+
return route;
15+
}, this);
1616
}
1717
}
18-
})
18+
});
1919

2020
Vue.component('breadcrumbs', {
2121
methods: {
2222
getBreadcrumb: function (bc) {
23-
return typeof bc === 'function' ? bc(this.$route.params) : bc
23+
return typeof bc === 'function' ? bc(this.$route.params) : bc;
2424
}
2525
},
2626
template: `
@@ -30,6 +30,6 @@ export default {
3030
</li>
3131
</ol>
3232
`
33-
})
33+
});
3434
}
35-
}
35+
};

0 commit comments

Comments
 (0)