A reactive immutable state management library for JavaScript/TypeScript applications built on RxJS.
Elf is a reactive immutable state management solution built on top of RxJS for JavaScript applications. It uses custom RxJS operators to query state and pure functions to update it, offering a powerful yet simple alternative to complex state management setups by eliminating boilerplate.
Frontend developers, particularly those working with Angular or React, who need a lightweight, modular state management library with built-in support for common patterns like entity management, pagination, and request caching.
Developers choose Elf for its modular, tree-shakeable design that reduces bundle size, its first-class TypeScript support, and its comprehensive built-in features like entity management, state persistence, and devtools, which simplify complex state logic without extensive boilerplate.
🧙♀️ A Reactive Store with Magical Powers
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Elf is split into composable packages like @ngneat/elf-entities and @ngneat/elf-persist-state, allowing selective imports to reduce bundle size, as highlighted in the README's tree-shakeable design.
Fully typed with first-class TypeScript support, ensuring type safety across state queries and updates, evident in the provided code examples with interfaces and generics.
Offers dedicated tools for normalized entity collections via packages like @ngneat/elf-entities, simplifying CRUD operations without boilerplate, as shown in the todos example with setEntities.
Includes utilities for request status tracking and caching through @ngneat/elf-requests, streamlining loading, error, and success states in asynchronous flows, per the features list.
Built entirely on RxJS, which mandates familiarity with reactive programming and adds bundle overhead if not already used, potentially alienating teams preferring simpler alternatives.
The composable package structure requires importing and configuring multiple modules (e.g., for persistence, entities), making initial setup more involved than all-in-one libraries like Redux Toolkit.
As a newer library, Elf has a smaller community and fewer third-party extensions compared to giants like NgRx or Zustand, which could hinder long-term support and resource availability.