More Premium Hugo Themes Premium React Themes

React Native Onyx

Persistent, offline-first state management solution for React Native. Easy to use with minimal config and boilerplate.

React Native Onyx

Persistent, offline-first state management solution for React Native. Easy to use with minimal config and boilerplate.

Author Avatar Theme by expensify
Github Stars Github Stars: 216
Last Commit Last Commit: Jan 12, 2026 -
First Commit Created: Feb 24, 2024 -
React Native Onyx screenshot

Overview

React-native-onyx is an impressive persistent storage solution wrapped in a Pub/Sub library. It allows for efficient storage and retrieval of data in key/value pairs and enables subscription to changes in data, notifying subscribers when data changes occur.

Features

  • Persistent Data Storage: Stores and retrieves data from persistent storage.
  • Key/Value Pairs: Data is stored as key/value pairs, accommodating various data types.
  • Pub/Sub Functionality: Allows other code to subscribe to changes in data and publishes change events accordingly.
  • Subscriber Initialization: Provides a framework for subscribers to get initialized with the current value of a key.
  • Integration with React Components: React components can easily subscribe to data changes using withOnyx().

Installation

To install Onyx, follow these steps:

  1. Add Onyx to your project using npm: npm install react-native-onyx.
  2. Initialize Onyx in your project by calling Onyx.init() with a configuration object.
  3. For non-react-native projects, utilize the browser field in package.json and import Onyx the same way as in react-native projects.

Summary

React-native-onyx offers a robust solution for persistent storage needs, with key features like efficient data storage, retrieval, and Pub/Sub functionality. By integrating easily with React components and providing simple methods for data storage and merging, Onyx proves to be a valuable tool for developers looking to streamline data management in their applications.