React Spaces

screenshot of React Spaces

React Spaces

React components that allow you to divide a page or container into nestable anchored, scrollable and resizable spaces.

Overview: React Spaces is a layout system that allows users to divide a page or container into scrollable, resizable, and nestable spaces. It provides a foundation for building user interfaces that can adapt to different viewport sizes. Unlike other UI component libraries, React Spaces focuses on layout functionality rather than visual components. It offers features such as anchoring, resizing, and positioning spaces within a container. The library does not provide any styling, giving users the flexibility to design their own layouts.


  • Easy to understand and nestable layout system
  • Anchored spaces allow for precise positioning within a container
  • Resizable spaces adapt to changes in viewport size
  • No visual elements or styling applied to spaces, users can fill them with their own components
  • Top-level spaces, such as ViewPort and Fixed, provide foundational structures for layouts
  • Fill space component automatically adjusts to available area in the container
  • Positioned spaces can be positioned absolutely within a parent space
  • Layer component enables the creation of layered spaces within a parent space
  • Centered and CenteredVertically components for content alignment

Installation: To use React Spaces, follow these steps:

  1. Ensure you have Node.js and npm installed on your machine.
  2. Open your terminal and navigate to the project directory.
  3. Run the following command to install React Spaces:
npm install react-spaces
  1. Import the necessary components in your project:
import { ViewPort, Fixed, Left, Right, Top, Bottom, Fill, Positioned, Layer, Centered, CenteredVertically } from 'react-spaces';
  1. You are now ready to use React Spaces in your application.

Summary: React Spaces is a flexible layout system that allows developers to easily create responsive user interfaces by dividing containers into scrollable, resizable, and nestable spaces. With features such as anchoring, positioning, and layering, React Spaces provides a solid foundation for building complex layouts that adapt to different viewport sizes. By separating layout functionality from visual components, React Spaces gives users the freedom to design their own UI elements while maintaining a consistent and responsive layout.


React is a widely used JavaScript library for building user interfaces and single-page applications. It follows a component-based architecture and uses a virtual DOM to efficiently update and render UI components


SCSS is a preprocessor scripting language that extends the capabilities of CSS by adding features such as variables, nesting, and mixins. It allows developers to write more efficient and maintainable CSS code, and helps to streamline the development process by reducing repetition and increasing reusability.

UI Kits & Components

A UI kit provides developers with a set of reusable components that can be easily integrated into a website or application. These components are pre-designed with consistent styling and functionality, allowing developers to save time and effort in the design and development process. UI kits can be either custom-built or third-party, and often include components for buttons, forms, typography, icons, and more.


RollupJS is a popular and efficient JavaScript module bundler that takes the code from multiple modules and packages them into a single optimized file, minimizing the overall size of the application and improving its performance.


TypeScript is a superset of JavaScript, providing optional static typing, classes, interfaces, and other features that help developers write more maintainable and scalable code. TypeScript's static typing system can catch errors at compile-time, making it easier to build and maintain large applications.