Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(resolve)!: makes alias type derivation more correct and precise B…
…REAKING (#867) ## Description - takes 'workspaces' field into account when merging package manifests - same for the 'imports' field - when determining what kind of an alias a thing is use the _parsed_ tsconfig to determine it - adds `alias-tsconfig-base-url` and `alias-tsconfig-paths` dependency types to distinguish between the two types of aliases one can use within tsconfigs. B.t.w. for both dependency-cruiser will keep emitting the `alias` and `alias-tsconfig` dependency types as well - both for convenience and backwards compatibility. This PR is theoretically 🚨 BREAKING as rules previously defined on aliases, that didn't fire now _will_ because they're now detected correctly. ## Motivation and Context Now we're doing explicit things with `workspaces` and `imports` fields we need to have them in merged package manifests as well, so in monorepos we still take them into account. The rewrite of the tsconfig alias detection logic is necessary to ensure we detect tsconfig aliases correctly and more precisely. Also see #863. ## How Has This Been Tested? - [x] green ci - [x] additional unit tests - [x] additional integration test(s) ## Types of changes - [x] Bug fix (non-breaking change which fixes an issue) - [ ] Documentation only change - [ ] Refactor (non-breaking change which fixes an issue without changing functionality) - [x] New feature (non-breaking change which adds functionality) - [x] Breaking change (fix or feature that would cause existing functionality to change)
- Loading branch information
Showing
47 changed files
with
853 additions
and
172 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.