-
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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(next): make defineConfig generic #12243
Conversation
🦋 Changeset detectedLatest commit: 4dad468 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 |
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.
This PR is blocked because it contains a minor
changeset. A reviewer will merge this at the next release if approved.
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.
I have no idea what the new TS code is doing 😅 but I saw the demo, and I liked it!
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.
Changeset looks good, but just checking that I don't see any specific error messages in this PR.
I'm fine with changing the order of locales
and defaultLocale
, but I'm not sure what if any docs changes would be required for this PR, since this doesn't change the fact that we do already say that the default locale must be in your list of supported locales. Happy for you to double check that in the docs repo though!
Co-authored-by: Sarah Rainsberger <[email protected]>
Changes
defineConfig
generic (backward compatible). That means that some parts of the config will be constrained by others. For example, it will ensure thati18n.defaultLocale
is one ofi18n.locales
at the type levelastro/config
works, by having one source of truth (fromconfig.d.ts
/config.mjs
tosrc/config/entrypoint.ts
being compiled)Testing
Should still pass, I added types tests
Docs
I'll do a docs PR about i18n once approved