Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat: Add new inject point - postBodyStart #646

Merged
merged 1 commit into from
Apr 29, 2023

Conversation

ImSingee
Copy link
Contributor

@ImSingee ImSingee commented Apr 28, 2023

PR Checklist

  • The commit message follows guidelines for NexT.
  • The changes have been tested (for bug fixes / features).
  • I will submit a PR for docs later Docs in NexT website have been added / updated (for features).

PR Type

  • Bugfix.
  • Feature.
  • Improvement.
  • Code style update (formatting, linting).
  • Refactoring (no functional changes).
  • Documentation.
  • Translation.
  • Other... Please describe:

What is the new behavior?

Add a new hook that can prepend data before the post content.

https://blog.singee.me/2023/04/21/439c2231088e47d6a36502ca5427dbf1/

The text 本文首发于 xlog,可跳转获得更佳阅读体验 is added with use of this inject.

How to use?

In NexT _config.yml:

custom_file_path:
  postBodyStart: source/_data/post-body-start.njk

@stevenjoezhang stevenjoezhang added this to the 8.16.0 milestone Apr 29, 2023
@stevenjoezhang stevenjoezhang merged commit e5d5026 into next-theme:master Apr 29, 2023
10 of 11 checks passed
@welcome
Copy link

welcome bot commented Apr 29, 2023

Congrats on merging your first pull request here! 🎉 How awesome!

gtn1024 pushed a commit to gtn1024/hexo-theme-next that referenced this pull request Jul 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants