Repository navigation
Conversation
🦋 Changeset detectedLatest commit: 2e10b97 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
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 |
✅ Deploy Preview for astro-starlight ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
I spent many hours this week trying to find a more "built-in" approach to this solution, even dug into the Zod codebase, but in the end, I personally didn't find a more elegant way to handle this. Considering this, I'm opening up this PR for review to see if anyone has any other ideas, discuss if we want to use this approach, etc. (but we still don't want to merge this PR if we go with this approach). |
|
Thanks @HiDeoo! I also opened colinhacks/zod#6191 in case someone might have ideas/suggestions, but I have the feeling Zod is a) massively used and gets a lot of incoming questions and b) not super actively maintained, so not sure if we’ll ever get a response. I’m torn — on the one hand this fixes the issue, but on the other it’s a headache to maintain. It might be good to figure out exactly which things it’s impossible to extend currently and decide if that behaviour is acceptable or not? There’s one side of me that thinks “ |
|
I'm definitely also torn and that'a also why I tried to find a better solution. Like you said, it's annoying to maintain, I'm pretty sure it's not 100% perfect and we could probably get issues about edge cases in the future (altho I would expect them to be minimal). Considering the use case is also understandable (while still niche), I wonder if I'm not tempted to say "let's try it" as a fix for But if someone has a strong opinion about this, stronger than me, I think I would definitely be to go along with it. |
|
Yeah, I’m OK with that. For code sanity it might be good to move the new code into a utility file so that |
|
Perfect. Considering this, I'll now close this PR for now (and we still have it in GH if ever needed for reference or something). |
|
Thanks again for figuring this out! |

Description
Temporary draft PR, do not merge.
See #3936 (comment) for context and conversations.