-
-
Notifications
You must be signed in to change notification settings - Fork 124
feat: generate content title from frontmatter #51
Conversation
60e0342
to
929b5ee
Compare
929b5ee
to
98cd5a4
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Love the feature to add title from the frontmatter @newsbielt703! Just a couple of comments and then I think we should merge!
@@ -18,6 +35,11 @@ tags: | |||
``` | |||
|
|||
## date | |||
|
|||
- Type: `YYYY-MM-DD` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will timezones be accepted as well? Best to document the standard if we're using ISO-8601 or something else
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
VuePress' using gray-matter
which depends js-yaml
which follows standard yaml types, so all available formats are here. I've updated the docs.
@@ -31,6 +53,10 @@ date: 2016-10-20 | |||
|
|||
## author | |||
|
|||
- Type: `string` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not critical to this PR, but what do you think about making Author an object instead so that people can define things like meta information (i.e., social media links, email, etc.)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What do you recommend to leverage those meta information? Currently, people can display contact infos by the option footer.contact
.
98cd5a4
to
1f0054f
Compare
BREAKING CHANGE: Require title in front matter
1f0054f
to
935edbf
Compare
Thanks a lot to you !
Sent from ProtonMail Mobile
…On Wed, Jan 29, 2020 at 10:13 AM, Billyyyyy3320 ***@***.***> wrote:
@newsbielt703 commented on this pull request.
---------------------------------------------------------------
In [styles/palette.styl](#51 (comment)):
> @@ -18,7 +18,6 @@ $footerColor = #828282
$newsletterBgColor = #f8f8f8
// layout
-$navbarHeight = 5rem
okay then I'll check out source code to see is there any other styles written with px should be refactored to use rem instead. Thanks the review.
—
You are receiving this because you commented.
Reply to this email directly, [view it on GitHub](#51), or [unsubscribe](https://github.com/notifications/unsubscribe-auth/ACYFLNGWPHFTPTRPR7CHG5DRAGMLJANCNFSM4KGVUVBQ).
|
Summary
Before:
After:
There's no need to write your title in the beginning of your content any more, but that's not the main reason to make this breaking change.
In #32, we need a head which contains tags, date, author and location in post content.
In #45, we need a hero image for each post. It should be displayed in not only post list page but also post content page.
The ideal position for both of them is under the content title, but it'll be complicated to insert them into the middle of content.
I've checked out several blog tools and found that it's common to write title in front matter. I'll not merge this PR until I submit the PRs for #32 and #45. We can also remove
modifyBlogPluginOptions
in the next major release.What kind of change does this PR introduce? (check at least one)
If changing the UI of default theme, please provide the before/after screenshot:
Does this PR introduce a breaking change? (check one)