Structured logging for Dart. Pipeline architecture, OTel-ready, works everywhere.
Click a package name for its full README — API reference, configuration examples, and integration recipes.
| Package | pub.dev | Coverage | Description |
|---|---|---|---|
| loq | Core structured logging | ||
| loq_shelf | Shelf / Dart Frog / Jaspr middleware | ||
| loq_drift | Drift query logging interceptor | ||
| loq_flutter | Flutter lifecycle, navigation, and error capture | ||
| loq_otel | coming soon | — | OpenTelemetry log bridge |
| loq_crashlytics | coming soon | — | Firebase Crashlytics adapter |
| loq_serverpod | coming soon | — | Serverpod integration |
| loq_sentry | coming soon | — | Sentry adapter |
import 'package:loq/loq.dart';
final log = Logger('payments');
log.info('processed', fields: {'orderId': 'abc-123', 'amount': 99.95});
// Bound loggers carry context
final reqLog = log.withFields({'requestId': 'req-456'});
reqLog.info('charging card'); // includes requestId
// Zone context flows through async code
withLogContext({'traceId': 'xyz'}, () async {
log.info('inside trace'); // includes traceId automatically
});# Clone and setup
git clone https://github.com/dartloq/loq.git
cd loq
dart pub get
melos bootstrap
# Run checks
melos run analyze
melos run testMIT. See LICENSE.