Skip to content
Efra Espada edited this page Jan 30, 2024 · 2 revisions

The object library provides utilities for serializing and deserializing Dart objects to and from JSON format. This library simplifies the process of converting Dart objects to JSON and vice versa, making it easier to work with JSON data in Dart applications.

Features

  • Automatic generation of serialization code for Dart classes using annotations.
  • Support for serializing and deserializing JSON data with minimal boilerplate code.
  • Customizable serialization behavior through annotations and configuration options.
  • Compatibility with popular Dart frameworks and tools, including Flutter.

Working with instances never was easiest.

SimpleSample? sample = {
  'id': 'id',
  'numberContent': 1,
  'integerContent': 2,
  'doubleContent': 3.0,
  'stringContent': 'string',
  'booleanContent': true,
}.asNullableInstance();

- Generate Serialization Code

- Create new instances

- Create a list of instances

- Create a map of instances

- Other types of instances

- Conversion safety