Allow specifying the name of the typescript declaration file#872
Merged
bakerkretzmar merged 1 commit into2.xfrom Feb 16, 2026
Merged
Allow specifying the name of the typescript declaration file#872bakerkretzmar merged 1 commit into2.xfrom
bakerkretzmar merged 1 commit into2.xfrom
Conversation
04d1473 to
98ebaea
Compare
98ebaea to
e1b56cc
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Allows passing a value to the
--typescommand option to put the types at a custom path instead ofresources/js/ziggy.d.ts. This is a bandaid solution for the 'module has no exported member Ziggy' issue, which I believe really does just boil down to the files being named the same, which they shouldn't be. I think changing the default name is a breaking change though, so adding this in the meantime.To fix the issue described in #828, #829, and #826, use
--types=resources/js/ziggy-routes.d.tsin your commands (or another path that is notresources/js/ziggy.d.ts).The default in the command signature is
"false"to remain compatible with existing command usage that either:--typesoption at all (in which case the command will now see"false"and not generate types)--typesjust like that, with no value (in which case the command will see it asnulland generate types at the default location)Closes #828.