Yarn Plugin API

Yarn ships with a full plugin API exposed by `@yarnpkg/core`. Plugins can register commands, resolvers, fetchers, linkers, and lifecycle hooks. Plugins are installed with `yarn plugin import` and listed/verified with `yarn plugin list`, `yarn plugin check`, and `yarn plugin runtime`. The default distribution bundles 20+ plugins including plugin-npm, plugin-pnp, plugin-workspace-tools, plugin-constraints, plugin-typescript, plugin-interactive-tools, and plugin-stage.

Yarn Plugin API is one of 10 APIs that Yarn publishes on the APIs.io network.

Tagged areas include Plugins, Extensibility, JavaScript, and SDK. The published artifact set on APIs.io includes API documentation.

API entry from apis.yml

apis.yml Raw ↑
aid: yarn-pkg:yarn-plugin-api
name: Yarn Plugin API
tags:
- Plugins
- Extensibility
- JavaScript
- SDK
humanURL: https://yarnpkg.com/advanced/plugin-tutorial
properties:
- url: https://yarnpkg.com/advanced/plugin-tutorial
  type: Documentation
- url: https://yarnpkg.com/api
  type: Documentation
- url: https://github.com/yarnpkg/berry/tree/master/packages/yarnpkg-core
  type: SourceCode
- url: https://yarnpkg.com/cli/plugin/import
  type: Documentation
- url: https://yarnpkg.com/cli/plugin/list
  type: Documentation
description: Yarn ships with a full plugin API exposed by `@yarnpkg/core`. Plugins can register commands,
  resolvers, fetchers, linkers, and lifecycle hooks. Plugins are installed with `yarn plugin import` and
  listed/verified with `yarn plugin list`, `yarn plugin check`, and `yarn plugin runtime`. The default
  distribution bundles 20+ plugins including plugin-npm, plugin-pnp, plugin-workspace-tools, plugin-constraints,
  plugin-typescript, plugin-interactive-tools, and plugin-stage.