Skip to content

Commit

Permalink
fix: prepend all breadcrumbs with Home, close #45
Browse files Browse the repository at this point in the history
  • Loading branch information
Scrum committed Jul 18, 2018
1 parent 8e9454e commit 00e2b1a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/vue-2-breadcrumbs.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ export default {
$breadcrumbs: {
get() {
const breadcrumbs = this.$route.matched.map(routeRecord => {
let path = routeRecord.path;
let path = routeRecord.path.length ? routeRecord.path : '/';
let route = routeRecord;

Object.keys(this.$route.params).forEach(param => {
Expand Down

0 comments on commit 00e2b1a

Please sign in to comment.