yarn unlink — Yarn CLI reference

Remove local links from the current project

Docs/Reference/CLI/unlink

yarn unlink

Remove local links from the current project

yarn unlink <TARGETS…>

This command removes portal: resolutions from the top-level manifest. It is the counterpart to yarn link.

If the --all flag is used without any arguments, Yarn will remove all resolutions that use the portal: protocol.

If the --all flag is used with a path argument, Yarn will unlink all workspaces from the specified project.

Otherwise, you can specify package names (with glob support) or paths to individual packages to unlink specific resolutions.

#--all, -Aboolean

Unlink all portal resolutions, or all workspaces from the target project