oref 0.3.0 copy "oref: ^0.3.0" to clipboard
oref: ^0.3.0 copied to clipboard

Oref is a lightweight, high-performance reactive programming library.

Oref #

Oref is a lightweight, high-performance reactive programming library for Dart. It provides a concise yet powerful way to manage application state and side effects.

Features #

  • 🚀 High Performance: Optimized reactive system ensures fast state updates with minimal overhead
  • 🧩 Modularity: Easy to integrate into existing projects without enforcing a specific application architecture
  • 🔍 Fine-grained Reactivity: Precisely tracks and updates dependencies, avoiding unnecessary computations
  • 🛠 Flexible API: Supports various reactive programming patterns, including refs, derived properties, and effects
  • 100% Native: Zero dependencies, pure Dart implementation

Installation #

Run the following command to install Oref:

dart pub add oref

Or add the following line to your pubspec.yaml file:

dependencies:
  oref: latest

Quick Start #

Here's a simple example demonstrating how to use Oref:

import 'package:oref/oref.dart';

void main() {
  final count = ref(0);
  final doubleCount = derived(() => count.value * 2);

  effect(() {
    print('Count: ${count.value}, Double: ${doubleCount.value}');
  });

  count.value++; // Will trigger the effect and print new values
}
1
likes
0
pub points
14%
popularity

Publisher

verified publisherodroe.dev

Oref is a lightweight, high-performance reactive programming library.

Homepage
Repository (GitHub)
View/report issues

Topics

#state #reactive #ref #derived #effect

Funding

Consider supporting this project:

github.com

License

unknown (license)

More

Packages that depend on oref