From 2aa9676c0ccf593dc0148f1f9a8649e3aeb24aad Mon Sep 17 00:00:00 2001 From: Rob Hogan Date: Wed, 30 Aug 2023 07:39:15 -0700 Subject: [PATCH] Document `resolver.unstable_enableSymlinks` Differential Revision: D48784988 fbshipit-source-id: 6f5c51fc77339d4f29a606a8a93cc4dd9ea91c89 --- docs/Configuration.md | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/docs/Configuration.md b/docs/Configuration.md index f6c593c05d..c67f9e9d5e 100644 --- a/docs/Configuration.md +++ b/docs/Configuration.md @@ -395,6 +395,30 @@ In a future release of Metro, this option will become `true` by default. --- +#### `unstable_enableSymlinks`
Experimental
+ +Type: `boolean` + +Enable experimental support for projects containing symbolic links (symlinks). + +When enabled, Metro traverses symlinks during module and asset [resolution](./Resolution.md), instead of ignoring symlinks. Note that, as with any other file Metro needs to resolve, the symlink target *must be within configured [watched folders](#watchfolders)* and not otherwise excluded. + +Defaults to `false`. + +:::info + +For example, if you have a Metro project within a [Yarn workspace](https://classic.yarnpkg.com/lang/en/docs/workspaces/) (a subdirectory of a Yarn workspace root), it's likely you'll want to include your workspace *root* path in your configured [`watchFolders`](#watchfolders) so that Metro can resolve other workspaces or hoisted `node_modules`. Similarly, to use [linked packages](https://classic.yarnpkg.com/lang/en/docs/cli/link/), you'll need to list those package source locations (or a containing directory) in [`watchFolders`](#watchfolders). + +::: + +:::note + +In a future release of Metro, this option will become `true` by default. + +::: + +--- + ### Transformer Options