cli
cli copied to clipboard
can not autolink or link native module when using npm7's worksapces
Node: 14.16.1 npm: 7.20.1
symbolic link has in node_modules
npm i
react-native link xxx
warn Calling react-native link [packageName] is deprecated in favor of autolinking. It will be removed in the next major release.
Autolinking documentation: https://github.com/react-native-community/cli/blob/master/docs/autolinking.md
error Unknown dependency. Make sure that the package you are trying to link is already installed in your
"node_modules" and present in your "package.json" dependencies.
info Run CLI with --verbose flag for more details.
In later versions of react-native
external modules are using auto-linking. Link
command is deprecated as the error message states. If you have problems with autolinking in your monorepo we have a document that should help you with some of the things. Also, monorepos and workspaces are tricky and I don't think I can help you without any reproducible demo.
There hasn't been any activity on this issue in the past 3 months, so it has been marked as stale and it will be closed automatically if no further activity occurs in the next 7 days.