bifrosted 0.2.2
bifrosted: ^0.2.2 copied to clipboard
The rainbow bridge connecting your app to APIs. A lightweight REST API client and repository pattern with caching, offline support, and error handling.
Changelog #
0.2.2 #
- Fixed build.yaml to correctly combine generated code into
.g.dartfiles- Changed
build_to: cacheandbuild_extensions: .fake.g.part - Generator output now properly merges with json_serializable/freezed
- Changed
0.2.1 #
- Added
build.yamlfor auto-discovery by build_runner- No manual configuration needed - just add the dependency and run build_runner
- Works like freezed/json_serializable out of the box
0.2.0 #
- Added
@generateFakeannotation for code generation - Added
FakeUtilsutility class (usesfakerpackage)fakeForKey(String key)- generates fake data based on field namecreate<T>()- generates fake model from factoryfakeJson()/fakeJsonList()- generic JSON generators
- Added
FakeGeneratorfor build_runner integration- Generates
.fake()extension methods for annotated classes - Works with freezed models
- Generates
0.1.1 #
- Updated README
0.1.0 #
- Initial release
RestAPIabstract class for REST API clients- GET, POST, PUT, PATCH, DELETE methods
- Automatic error handling and logging
- Header management with extra headers support
BifrostRepositoryfor repository pattern with cachingfetch<T>()andfetchList<T>()for automatic deserialization- Offline-first with cache fallback
- Automatic cache expiration
SystemNotifierinterface for global error handlingonNetworkError(),onUnauthorized(),onForbidden()onServerError(),onApiError()
StorageServiceinterface for pluggable storage backendsConnectionCheckerinterface for connectivity detection- Uses
loggerpackage for logging - Comprehensive test suite