Skip to content

Commit

Permalink
fix($core): Search result cannot jump to the correct hash anchor (close
Browse files Browse the repository at this point in the history
…: #1594) (#1599)
  • Loading branch information
ulivz committed May 14, 2019
1 parent fda5476 commit e6af68f
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions packages/@vuepress/core/lib/client/components/Content.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import { getPageAsyncComponent } from '../util'

export default {
props: {
Expand All @@ -10,9 +9,8 @@ export default {
},
render (h) {
const pageKey = this.pageKey || this.$parent.$page.key
const pageComponent = getPageAsyncComponent(pageKey)
if (pageComponent) {
return h(pageComponent)
if (pageKey) {
return h(pageKey)
}
return h('')
}
Expand Down

0 comments on commit e6af68f

Please sign in to comment.