diff --git a/workspaces/arborist/README.md b/workspaces/arborist/README.md index 81d79cbf3021b..8a111f3c70fe2 100644 --- a/workspaces/arborist/README.md +++ b/workspaces/arborist/README.md @@ -267,53 +267,19 @@ are updated by arborist when necessary whenever the tree is modified in such a way that the dependency graph can change, and are relevant when pruning nodes from the tree. -``` -| extraneous | peer | dev | optional | devOptional | meaning | prune? | -|------------+------+-----+----------+-------------+---------------------+-------------------| -| | | | | | production dep | never | -|------------+------+-----+----------+-------------+---------------------+-------------------| -| X | N/A | N/A | N/A | N/A | nothing depends on | always | -| | | | | | this, it is trash | | -|------------+------+-----+----------+-------------+---------------------+-------------------| -| | | X | | X | devDependency, or | if pruning dev | -| | | | | not in lock | only depended upon | | -| | | | | | by devDependencies | | -|------------+------+-----+----------+-------------+---------------------+-------------------| -| | | | X | X | optionalDependency, | if pruning | -| | | | | not in lock | or only depended on | optional | -| | | | | | by optionalDeps | | -|------------+------+-----+----------+-------------+---------------------+-------------------| -| | | X | X | X | Optional dependency | if pruning EITHER | -| | | | | not in lock | of dep(s) in the | dev OR optional | -| | | | | | dev hierarchy | | -|------------+------+-----+----------+-------------+---------------------+-------------------| -| | | | | X | BOTH a non-optional | if pruning BOTH | -| | | | | in lock | dep within the dev | dev AND optional | -| | | | | | hierarchy, AND a | | -| | | | | | dep within the | | -| | | | | | optional hierarchy | | -|------------+------+-----+----------+-------------+---------------------+-------------------| -| | X | | | | peer dependency, or | if pruning peers | -| | | | | | only depended on by | | -| | | | | | peer dependencies | | -|------------+------+-----+----------+-------------+---------------------+-------------------| -| | X | X | | X | peer dependency of | if pruning peer | -| | | | | not in lock | dev node hierarchy | OR dev deps | -|------------+------+-----+----------+-------------+---------------------+-------------------| -| | X | | X | X | peer dependency of | if pruning peer | -| | | | | not in lock | optional nodes, or | OR optional deps | -| | | | | | peerOptional dep | | -|------------+------+-----+----------+-------------+---------------------+-------------------| -| | X | X | X | X | peer optional deps | if pruning peer | -| | | | | not in lock | of the dev dep | OR optional OR | -| | | | | | hierarchy | dev | -|------------+------+-----+----------+-------------+---------------------+-------------------| -| | X | | | X | BOTH a non-optional | if pruning peers | -| | | | | in lock | peer dep within the | OR: | -| | | | | | dev hierarchy, AND | BOTH optional | -| | | | | | a peer optional dep | AND dev deps | -+------------+------+-----+----------+-------------+---------------------+-------------------+ -``` +| extraneous | peer | dev | optional | devOptional | meaning | prune? | +|:----------:|:----:|:---:|:--------:|:----------------:|:-------------------------------------------------------------------------------------------------|:-------------------------------------------------------| +| | | | | | production dep | never | +| X | N/A | N/A | N/A | N/A | nothing depends on this, it is trash | always | +| | | X | | X
not in lock | devDependency, or only depended
on by devDependencies | if pruning dev | +| | | | X | X
not in lock | optionalDependency, or only depended
on by optionalDeps | if pruning optional | +| | | X | X | X
not in lock | Optional dependency of dep(s) in the
dev hierarchy | if pruning EITHER
dev OR optional | +| | | | | X
in lock | BOTH a non-optional dep within the
dev hierarchy, AND a dep within
the optional hierarchy | if pruning BOTH
dev AND optional | +| | X | | | | peer dependency, or only depended
on by peer dependencies | if pruning peers | +| | X | X | | X
not in lock | peer dependency of dev node hierarchy | if pruning peer OR
dev deps | +| | X | | X | X
not in lock | peer dependency of optional nodes, or
peerOptional dep | if pruning peer OR
optional deps | +| | X | X | X | X
not in lock | peer optional deps of the dev dep hierarchy | if pruning peer OR
optional OR dev | +| | X | | | X
in lock | BOTH a non-optional peer dep within the
dev hierarchy, AND a peer optional dep | if pruning peer deps OR:
BOTH optional AND dev deps | * If none of these flags are set, then the node is required by the dependency and/or peerDependency hierarchy. It should not be pruned.