List installed packages.
yarn list
yarn list
The yarn list
command mimics the expected Unix behavior of listing. In Yarn, the list
command lists all dependencies for the current working directory by referencing all package manager meta data files, which includes a project’s dependencies.
yarn list vx.x.x ├─ [email protected] ├─ [email protected] │ └─ package-3@^2.1.0 └─ [email protected]
yarn list [--depth]
By default, all packages and their dependencies will be displayed. To restrict the depth of the dependencies, you can add a flag, --depth
, along with the desired level to the list
command.
yarn list --depth=0
Keep in mind, levels are zero-indexed.
© 2016–2017 Yarn Contributors
Licensed under the BSD License.
https://yarnpkg.com/en/docs/cli/ls