otter_json_generator 2.0.0 copy "otter_json_generator: ^2.0.0" to clipboard
otter_json_generator: ^2.0.0 copied to clipboard

outdated

JSON serialization with code generation. Separate generated code from source and keep everything clean.

example/lib/example.dart

library example;

import 'package:otter_json/otter_json.dart';

@ImportJsonModule([DefaultJsonModule])
class ExampleImportJsonModule {}

class Example implements Json {
  final String name;
  final int age;
  final double money;
  final List<int> list;
  final Map<String, int> map;
  final AnotherExample example2;
  final List<AnotherExample> example2s;

  Example({
    required this.name,
    required this.age,
    required this.money,
    required this.list,
    required this.map,
    required this.example2,
    required this.example2s,
  });
}

class AnotherExample implements Json {
  final String name;

  AnotherExample({required this.name});
}
0
likes
0
pub points
0%
popularity

Publisher

unverified uploader

JSON serialization with code generation. Separate generated code from source and keep everything clean.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

analyzer, build, glob, meta, otter_json, path, source_gen

More

Packages that depend on otter_json_generator