azu / monorepo-utils

A collection of utilities for monorepo/lerna. Tools for TypeScript project references etc..
164 stars 10 forks source link

workspaces-to-typescript-project-references: Dependency resolution logic doesn't match yarn #59

Open Woodz opened 2 years ago

Woodz commented 2 years ago

Based on https://github.com/azu/monorepo-utils/blob/8ccf1c70c2582770ee6fc5fd71bf3b6e5e95400f/packages/%40monorepo-utils/workspaces-to-typescript-project-references/src/manager/workspaces.ts#L26-L30, the dependency resolution logic is:

This does not match the Yarn resolution logic in at least the following scenarios:

I recommend avoiding re-implementing the dependency resolution logic in this library and instead re-using the resolution logic of the build tool chosen by the plugin