chore: reconfigure tsc to run at the root, not for each package individually #1597
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.
About the Contributor
This pull request is posted on behalf of Superfly
Type of Contribution
This is a: Code improvement
Current Behavior
When building the TS, we are using lerna to spawn tsc for each package individually.
This makes it rather memory hungry, and if an error is encountered typically means running it all again
New Behavior
This now utilises the typescript projects and references functionality. There is a single 'root' tsconfig inside packages, which will build and typecheck everything in one go.
This means that there is one stream of type error output, which shows everything in one go with one count of number of errors. Fixing one error will reflect that in all referencing projects instead of burying errors higher up the terminal history.
A crude memory test locally, spawning in watch mode:
I have not touched the openapi package in this, as that was commonly excluded to avoid a dependency on java.
Testing
Affected areas
Time Frame
Other Information
Status