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

Process empty markdown body for remark/rehype plugins #12920

Merged
merged 2 commits into from
Jan 7, 2025
Merged

Conversation

bluwy
Copy link
Member

@bluwy bluwy commented Jan 7, 2025

Changes

fix #12800

Process empty markdown content as remark or rehype plugins may add content or frontmatter that may be used by end-users.

Testing

Added a new test

Docs

n/a. bug fix

Copy link

changeset-bot bot commented Jan 7, 2025

🦋 Changeset detected

Latest commit: 829e82f

The changes in this PR will be included in the next version bump.

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions github-actions bot added the pkg: astro Related to the core `astro` package (scope) label Jan 7, 2025
@ematipico
Copy link
Member

With "empty markdown", I thought of an empty file. Maybe worth rewording it

Copy link

codspeed-hq bot commented Jan 7, 2025

CodSpeed Performance Report

Merging #12920 will not alter performance

Comparing markdown-empty (24a8da6) with main (2ffc0fc)

Summary

✅ 4 untouched benchmarks

.changeset/pink-years-warn.md Outdated Show resolved Hide resolved
@bluwy bluwy changed the title Process empty markdown for remark/rehype plugins Process empty markdown body for remark/rehype plugins Jan 7, 2025
@bluwy
Copy link
Member Author

bluwy commented Jan 7, 2025

I believe it also handles if the markdown is completely empty, but I don't have a test for that. I've updated the changeset and PR title.

@bluwy bluwy merged commit 8b9d530 into main Jan 7, 2025
2 checks passed
@bluwy bluwy deleted the markdown-empty branch January 7, 2025 15:05
@astrobot-houston astrobot-houston mentioned this pull request Jan 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pkg: astro Related to the core `astro` package (scope)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Markdown files without content miss custom frontmatter added via remark plugin
3 participants