Skip to content
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

example config to be propagated across packages #1279

Closed
wants to merge 3 commits into from

Conversation

alexforsyth
Copy link
Contributor

Issue #, if available:

Description of changes:

Experimental PR to show how we'd implement a root tsconfig. This works properly for the abort controller package

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@alexforsyth
Copy link
Contributor Author

alexforsyth commented Jun 16, 2020

Key points:

  1. There is now a root ts-config, we'll put all the common ts options there.
  2. Individual packages no longer have a tsconfig. This is because vscode looks for the nearest tsconfig in the tree. By removing it, vscode jumps to using the root tscofig and provides all sorts of awesome goodies like paths and automatically highlighting places that do not adhere to the root tsconfig options.
  3. Individual packages still have a tsconfig.test.json. This inherits from the root tsconfig. Used by lerna when we want to build tsc.

@codecov-commenter
Copy link

Codecov Report

❗ No coverage uploaded for pull request head (experimental/root-tsconfig@b1f627a). Click here to learn what that means.
The diff coverage is n/a.


"module": "commonjs",
"moduleResolution": "node",
"target": "es5",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

target should be browser TSConfig target, as that's usually the lower version of ECMAScript.

"module": "commonjs",
"moduleResolution": "node",
"target": "es5",
"lib": ["es2015", "dom"],
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

decided to exclude lib, as it's overridden in individual clients

@github-actions
Copy link

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs and link to relevant comments in this thread.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jan 19, 2021
@trivikr trivikr deleted the experimental/root-tsconfig branch May 14, 2021 18:00
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants