-
Notifications
You must be signed in to change notification settings - Fork 198
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
Clarify documentation on tsconfig usage #2062
Comments
Thanks for the clarification! I would expect most of these type of tools to automatically load the existing
I, personally, don't mind breaking CLI changes if they allow for more flexibility down the line. |
The tool should definitely work without a tsconfig file but I think it makes sense to load the default file at the default paths (same way as tsc). We can make in a new major version. I'm cool with that. |
Awesome, @slhck, would you want to work on a PR for this? Remember to add unit tests :) |
And use the logic from tsc for finding the file if possible. |
Oh, actually I was referring to providing a PR for the docs only to address the current behavior. I'm not sure if I can change the package internals. So you mean just adding a new default value for the tsconfig option? |
This looks up the default tsconfig.json file for the current project when used from the CLI, to avoid possible compliation errors. Fixes vega#2062
This looks up the default tsconfig.json file for the current project when used from the CLI, to avoid possible compliation errors. Fixes vega#2062
This looks up the default tsconfig.json file for the current project when used from the CLI, to avoid possible compliation errors. Fixes vega#2062
Per #168 I understand that
tsconfig.json
is not read by default. This was confusing to me, as I have a project where building schemas failed due to this error:Yet in my
tsconfig.json
I have specified ES2023 as a target.I only then realized that I needed to explicitly pass the
tsconfig.json
file to the command to make it work. Just from the CLI args I would have assumed that "Custom tsconfig.json path" means: "Any config other thantsconfig.json
".Is that behavior intentional? (One would assume that proper type compilation also requires knowing about the project's build target, but maybe this is not as big of a problem as I think it is for most users.)
It would be great if the documentation could be updated to reflect that aspect. Maybe I'm the first one to get bitten by this, but from a quick review I haven't found similar issues. Let me know how you think this could be best addressed and I can provide a PR!
The text was updated successfully, but these errors were encountered: