Resizable split panes for React, derived from VS Code
See the codeReact split-pane component.
Docs · Examples · API · Changelog
npm install allotment
Allotment requires React 17, 18 or 19 (react and react-dom are peer dependencies).
import { Allotment } from "allotment";
import "allotment/dist/style.css";
export const App = () => (
<div style={{ height: 400 }}>
<Allotment>
<div>Pane A</div>
<div>Pane B</div>
</Allotment>
</div>
);
Allotment fills its parent element, so make sure the parent has a height. See the FAQ if nothing is showing.
The documentation has live examples of everything Allotment can do.
Allotment and Allotment.PaneAllotment aims to reproduce the behaviour of VS Code's split view. If you need something different, react-resizable-panels is a popular alternative.
Contributions are welcome! See the contributing guide to get started, and please follow the Code of Conduct.
Notable changes are recorded in the changelog.
Allotment is released under the MIT License.
533 followers · starred Sep 2024
1,537 followers · starred Jan 2022
178 followers · starred Oct 2024
823 followers · starred Jan 2024
Resizable split panes for React, derived from VS Code
See the codeReact split-pane component.
Docs · Examples · API · Changelog
npm install allotment
Allotment requires React 17, 18 or 19 (react and react-dom are peer dependencies).
import { Allotment } from "allotment";
import "allotment/dist/style.css";
export const App = () => (
<div style={{ height: 400 }}>
<Allotment>
<div>Pane A</div>
<div>Pane B</div>
</Allotment>
</div>
);
Allotment fills its parent element, so make sure the parent has a height. See the FAQ if nothing is showing.
The documentation has live examples of everything Allotment can do.
Allotment and Allotment.PaneAllotment aims to reproduce the behaviour of VS Code's split view. If you need something different, react-resizable-panels is a popular alternative.
Contributions are welcome! See the contributing guide to get started, and please follow the Code of Conduct.
Notable changes are recorded in the changelog.
Allotment is released under the MIT License.
533 followers · starred Sep 2024
1,537 followers · starred Jan 2022
178 followers · starred Oct 2024
823 followers · starred Jan 2024