Skip to content

fix(open_graph): remove index.html from url#3661

Merged
curbengh merged 7 commits intohexojs:masterfrom
curbengh:ograph-canonical
Sep 27, 2019
Merged

fix(open_graph): remove index.html from url#3661
curbengh merged 7 commits intohexojs:masterfrom
curbengh:ograph-canonical

Conversation

@curbengh
Copy link
Contributor

@curbengh curbengh commented Aug 10, 2019

What does it do?

Uses canonical url (the one that doesn't end with index.html) for open graph tags.

How to test

git clone -b ograph-canonical https://github.com/curbengh/hexo.git
cd hexo
npm install
npm test

Pull request tasks

  • Add test cases for the changes.
  • Passed the CI test.

@coveralls
Copy link

coveralls commented Aug 10, 2019

Coverage Status

Coverage increased (+0.002%) to 97.25% when pulling 7f61736 on curbengh:ograph-canonical into ffe4eaa on hexojs:master.

@curbengh
Copy link
Contributor Author

Related to #1306

@SukkaW SukkaW requested a review from segayuu August 27, 2019 14:13
segayuu
segayuu previously approved these changes Aug 27, 2019
Copy link
Contributor

@segayuu segayuu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@curbengh curbengh changed the title fix(open_graph): remove index.html from url WIP fix(open_graph): remove index.html from url Aug 28, 2019
@curbengh
Copy link
Contributor Author

curbengh commented Aug 28, 2019

Please don't merge this yet, I would like to introduce canonical_url option which also remove "index.html" from post.permalink. Once that option is available, we can use the option to decide whether to process this.url.

Edit: Pending #3691

Edit: Uses config.pretty_urls.trailing_index.

@curbengh curbengh changed the title WIP fix(open_graph): remove index.html from url fix(open_graph): remove index.html from url Sep 23, 2019
@curbengh curbengh added this to the v4.0.0 milestone Sep 27, 2019
@curbengh curbengh requested a review from a team September 27, 2019 03:20
@curbengh curbengh merged commit af99506 into hexojs:master Sep 27, 2019
@curbengh curbengh deleted the ograph-canonical branch September 27, 2019 05:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants