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

Expose ContentConfig type from astro:content #9840

Merged
merged 2 commits into from
Jan 27, 2024

Conversation

delucis
Copy link
Member

@delucis delucis commented Jan 26, 2024

Changes

  • Exports the ContentConfig type publicly from astro:content
  • We realised in "Virtual" pages prototype starlight#1175 that we needed access not just to a user’s schema output type (CollectionEntry['data']), but also the schema input type. While accessing the actual schema at runtime is possible, getting its type is much trickier. Exposing this would make that simpler. (Also open to other ideas if people have them.)

Testing

Existing tests should pass; types only change.

Docs

n/a — this is a rarely needed API, but handy in some edge cases.

Copy link

changeset-bot bot commented Jan 26, 2024

🦋 Changeset detected

Latest commit: f164bb5

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 26, 2024
@delucis delucis requested a review from bholmesdev January 26, 2024 23:40
@ematipico ematipico merged commit 70fdf1a into main Jan 27, 2024
13 checks passed
@ematipico ematipico deleted the chris/expose-content-config-type branch January 27, 2024 06:44
@astrobot-houston astrobot-houston mentioned this pull request Jan 27, 2024
delucis added a commit to Fryuni/starlight that referenced this pull request Feb 9, 2024
Makes sure we include withastro/astro#9840 which will be needed for withastro#1175
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.

2 participants