json_serializable_fic 1.0.0 copy "json_serializable_fic: ^1.0.0" to clipboard
json_serializable_fic: ^1.0.0 copied to clipboard

Adding support for fast immutable collections for json_serializable

example/main.dart

import 'package:fast_immutable_collections/fast_immutable_collections.dart';
import 'package:json_annotation/json_annotation.dart';

part 'main.g.dart';

@JsonSerializable()
class Model {
  final IList<int> myIntList;

  Model({required this.myIntList});

  factory Model.fromJson(Map<String, dynamic> json) => _$ModelFromJson(json);

  Map<String, dynamic> toJson() => _$ModelToJson(this);
}

void main() {
  print(Model(myIntList: [1, 2, 3].toIList()).toJson());
}
0
likes
50
points
72
downloads

Publisher

verified publisherdemoda.app

Weekly Downloads

Adding support for fast immutable collections for json_serializable

Repository (GitHub)
View/report issues

License

BSD-3-Clause (license)

Dependencies

analyzer, build, build_runner, json_annotation, json_serializable, json_serializable_fic_typehelpers, source_gen

More

Packages that depend on json_serializable_fic