to_string 0.1.0 icon indicating copy to clipboard operation
to_string: ^0.1.0 copied to clipboard

outdated

A tools for generating toString method for class, based on build_runner

example/example.dart

import 'package:to_string/to_string.dart';

part 'example.g.dart';

@ToString()
class Cat {
  Cat({this.color, this.weight, this.wings});

  final classify = "Animal";

  String color;

  double weight;

  String wings;

  /// toString() will return like this:
  ///
  /// ```dart
  /// 'Cat{classify: Animal, color: white, weight: 1.14, wings: null}';
  /// ```
  @override
  String toString() {
    return _$CatToString(this);
  }
}
9
likes
0
pub points
70%
popularity

A tools for generating toString method for class, based on build_runner

Repository (GitHub)
View/report issues

License

unknown (LICENSE)

More

Packages that depend on to_string