Skip to content

Commit

Permalink
fix: prioritize frontmatter's title, description and lang (#180)
Browse files Browse the repository at this point in the history
close #177 close #184
  • Loading branch information
ulivz authored and yyx990803 committed Apr 20, 2018
1 parent 3757c6c commit 384c5c7
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/app/dataMixin.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,13 @@ export default {
return targetLang || defaultLang || {}
},
$title () {
return this.$localeConfig.title || this.$site.title || ''
return this.$page.frontmatter.title || this.$localeConfig.title || this.$site.title || ''
},
$description () {
return this.$localeConfig.description || this.$site.description || ''
return this.$page.frontmatter.description || this.$localeConfig.description || this.$site.description || ''
},
$lang () {
return this.$localeConfig.lang || 'en-US'
return this.$page.frontmatter.lang || this.$localeConfig.lang || 'en-US'
},
$localePath () {
return this.$localeConfig.path || '/'
Expand Down

0 comments on commit 384c5c7

Please sign in to comment.