Enterprise-Grade
Local-First Sync Engine
Production-ready synchronization infrastructure for Flutter. Built with Isar, powered by event-driven architecture, designed for mission-critical applications.
Local Storage
- Isar Database
- Offline Queue
- Version Tracking
Sync Engine
- Event-Driven
- Conflict Resolution
- Auto-Retry Logic
Backend Adapters
- REST API
- Firebase
- Supabase
Developer Experience First
Clean API. Zero boilerplate. Production ready.
Installation
dependencies:
synclayer: ^0.2.0-beta.5
# Run
flutter pub getInitialization
await SyncLayer.init(
SyncConfig(
baseUrl: 'https://api.example.com',
collections: ['todos', 'users'],
conflictStrategy: ConflictStrategy.lastWriteWins,
),
);CRUD Operations
// Create
final id = await SyncLayer
.collection('todos')
.save({'text': 'Buy milk', 'done': false});
// Read
final todo = await SyncLayer
.collection('todos')
.get(id);
// Update
await SyncLayer
.collection('todos')
.save({'done': true}, id: id);
// Delete
await SyncLayer
.collection('todos')
.delete(id);Real-time Updates
// Watch for changes
SyncLayer
.collection('todos')
.watch()
.listen((todos) {
print('Updated: ${todos.length} items');
});
// Manual sync
await SyncLayer.syncNow();Built for Scale
Enterprise-grade features out of the box
Isar-Powered Storage
Lightning-fast local database with zero-copy object access and ACID compliance
Event-Driven Architecture
Reactive sync engine with comprehensive event system for monitoring and debugging
Conflict Resolution
Configurable strategies: last-write-wins, server-wins, client-wins with version tracking
Intelligent Retry
Exponential backoff with configurable max retries and automatic queue management
Connectivity Aware
Automatic network detection with seamless offline-to-online transitions
Backend Agnostic
Adapter pattern for any backend: REST, Firebase, Supabase, Appwrite, or custom
Performance Benchmarks
Technical Comparison
| Feature | SyncLayer | Firebase | Supabase | Drift |
|---|---|---|---|---|
| Offline-First | ✓ | ✓ | ✗ | ✓ |
| Auto-Sync | ✓ | ✓ | ✗ | ✗ |
| Backend Agnostic | ✓ | ✗ | ✗ | ✓ |
| Conflict Resolution | ✓ | ✓ | ✗ | ✗ |
| Event System | ✓ | ✓ | ✓ | ✗ |
| Type-Safe | ✓ | ✓ | ✓ | ✓ |
| Package Size | 312 KB | ~2 MB | ~1.5 MB | ~500 KB |
| Free Tier | ✓ | Limited | Limited | ✓ |
Ready for Production
Join developers building the next generation of offline-first applications