Skip to main content

Packages

Here we list all React Flow packages that we are publishing on npm.

Main Package

We recommend to use the reactflow package. It contains the following packages:

These packages are not part of the main package and need to be installed separately:

Installation

npm install reactflow

All examples and guides are using the reactflow package. If you only want to use parts of it, you can install the sub packages.

Sub Packages

The reactflow package contains multiple packages that can be installed separately. All packages are published under the @reactflow organization on npm. All of the following packages only use named exports.

@reactflow/core

The core package exports the main <ReactFlow /> component, the <ReactFlowProvider />, all hooks and all util functions:

Installation

npm install @reactflow/core

Usage

import { ReactFlow, useReactFlow } from '@reactflow/core';

@reactflow/background

This package exports the Background component.

Installation

npm install @reactflow/background

Usage

import { Background } from '@reactflow/background';

@reactflow/controls

This package exports the Controls and ControlButton component.

Installation

npm install @reactflow/controls

Usage

import { Controls, ControlButton } from '@reactflow/controls';

@reactflow/minimap

This package exports the MiniMap component.

Installation

npm install @reactflow/minimap

Usage

import { MiniMap } from '@reactflow/minimap';

@reactflow/node-toolbar

This package exports the NodeToolbar component.

Installation

npm install @reactflow/node-toolbar

Usage

import { NodeToolbar } from '@reactflow/node-toolbar';

@reactflow/node-resizer

This package exports the NodeResizer component.

Installation

npm install @reactflow/node-resizer

Usage

import { NodeResizer, NodeResizeControl } from '@reactflow/node-resizer';