Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit d193931

Browse files
committedApr 20, 2018
fix: prioritize frontmatter's title and lang (close: #177)
1 parent 748fa7f commit d193931

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed
 

Diff for: ‎lib/app/dataMixin.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -47,13 +47,13 @@ export default {
4747
return targetLang || defaultLang || {}
4848
},
4949
$title () {
50-
return this.$localeConfig.title || this.$site.title || ''
50+
return this.$page.frontmatter.title || this.$localeConfig.title || this.$site.title || ''
5151
},
5252
$description () {
53-
return this.$localeConfig.description || this.$site.description || ''
53+
return this.$page.frontmatter.title || this.$localeConfig.description || this.$site.description || ''
5454
},
5555
$lang () {
56-
return this.$localeConfig.lang || 'en-US'
56+
return this.$page.frontmatter.lang || this.$localeConfig.lang || 'en-US'
5757
},
5858
$localePath () {
5959
return this.$localeConfig.path || '/'

0 commit comments

Comments
 (0)
Please sign in to comment.