Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion docs/autolinking.md
Original file line number Diff line number Diff line change
Expand Up @@ -135,12 +135,14 @@ We can leverage CLI configuration to make it "see" React Native libraries that a
module.exports = {
dependencies: {
'local-rn-library': {
root: '/root/libraries',
root: path.join(__dirname, '/path/to/local-rn-library'),
},
},
};
```

> Note: In the `root` field, it's recommended to use `__dirname` instead of `process.cwd()`. This ensures the path is consistently resolved, regardless of the current working directory.

## How can I use autolinking in a monorepo?

There is nothing extra you need to do - monorepos are supported by default.
Expand Down
2 changes: 1 addition & 1 deletion docs/projects.md
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ Another use-case would be supporting local libraries that are not discoverable f
module.exports = {
dependencies: {
'local-rn-library': {
root: '/root/libraries',
root: path.join(__dirname, '/path/to/library'),
},
},
};
Expand Down