Flow doesn't preserve symlinks
- Dominant language
- Rust
- Stars
- 22.3k
- Forks
- 1.9k
- PR merge metrics
- No merged PRs in 30d
Description
Node has a --preserve-symlinks flag, which will allow package resolution to work correctly when using `lerna` or `npm link` with peerDependencies. Flow doesn't seem to have any understanding for symlinks, which means that it will consistently fail to check peerDependencies.
Test case: https://github.com/joshduck/test-flow/tree/master
```
# Run node using --preserve-symlinks flag:
npm run start
> A thinks a simple package is at /Users/duckj6g/Projects/test-flow/packages/a/node_modules/a-simple-package/index.js
> B thinks a simple package is at /Users/duckj6g/Projects/test-flow/packages/a/node_modules/a-simple-package/index.js
# Flow is unable to preserve symlinks:
npm run flow
> lerna ERR! execute Error: ../b/index.js:2
> lerna ERR! execute 2: const simple = require('a-simple-package');
> lerna ERR! execute ^^^^^^^^^^^^^^^^^^ a-simple-package. Required module not found
```
Contributor guide
Assessment
This issue has not been assessed yet.