FLUTTER ECOSYSTEM

smartstruct

smartstruct - A dart bean mapper annotation processor - the easy nullsafe way!

Latest version
1.4.0
30-day downloads
310
Likes
48
Pub points
160

Package Overview

Selection guidance generated from public package information. For reference only.

Overview

smartstruct is a Dart annotation processor that simplifies bean mapping between classes, enabling null-safe and type-safe data transformation with minimal boilerplate. It generates efficient code at compile time, reducing runtime overhead and improving performance. Ideal for developers working with complex data models across different layers of an application, such as from API responses to domain objects or view models. The package supports all major Flutter platforms and integrates seamlessly via a simple pub add command.

Use cases
  • Mapping API responses to domain models
  • Converting DTOs to view models
  • Simplifying data layer transformations
  • Automating repetitive object mapping logic
  • Enabling null-safe data transfers
Key features
  • Compile-time code generation
  • Null-safety by design
  • Minimal boilerplate
  • Supports all Flutter platforms
  • Easy integration via pub
  • Type-safe mappings
Suitable for
  • Flutter developers using data binding
  • Teams managing complex data models
  • Projects requiring high performance and safety
  • Developers avoiding manual mapping
  • Apps with frequent data model changes
Considerations
  • Requires build_runner for code generation
  • Needs understanding of annotations
  • May increase build time slightly
  • Not suitable for runtime dynamic mapping
  • Limited to static class structures
Supported platformsAndroidiOSWebmacOSWindowsLinux

Install package

flutter pub add smartstruct

Categories

Related projects

No data available yet.