Skip to content

trimFileName no longer works in a monorepo #404

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

Closed
ecraig12345 opened this issue Dec 9, 2021 · 0 comments · Fixed by #405
Closed

trimFileName no longer works in a monorepo #404

ecraig12345 opened this issue Dec 9, 2021 · 0 comments · Fixed by #405

Comments

@ecraig12345
Copy link
Contributor

#392 changed the behavior of trimming filenames so that it no longer works properly on types coming from node_modules in a monorepo, where commands may be run from a particular package but dependencies are installed at the repo root.

For example, I might run commands from an individual package /Users/me/my-repo/packages/foo, but the React typings are installed at the root, /Users/me/my-repo/node_modules/@types/react/index.d.ts.

Previously, the parent/declaration filename for props derived from React types would come back as my-repo/node_modules/@types/react/index.d.ts. Then we used a propFilter to exclude props coming from that file.

After #392, the filename in this case is just index.d.ts, which breaks the filtering.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant