meta_types_generator 0.1.0

  • Example
  • Installing
  • Versions
  • 47


  • Add meta_types_generator and build_runner to your dev_dependencies
  • generate code by running pub run build_runner run

See meta_types/example for examples on how to write model definitions.


  • Always use generated classes in code.
  • Always use definition classes when referencing other metatypes in your definitions.
  • Sealed classes should never extend, only implement others.
  • Interfaces cannot have computed accessors.
  • Additional functionality can be added to any meta type by generating additional mixins.


  • initial builder for union, enum, and data classes


/// See meta_types example for code examples.
/// use `pub run build_runner build` to run the generator
/// make sure build_runner and meta_types_generator are
/// dev_dependencies in you pubspec.yaml

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:

  meta_types_generator: ^0.1.0

2. Install it

You can install packages from the command line:

with pub:

$ pub get

Alternatively, your editor might support pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:

import 'package:meta_types_generator/builder.dart';
import 'package:meta_types_generator/generator_api.dart';
Version Uploaded Documentation Archive
0.1.0 Aug 7, 2018 Go to the documentation of meta_types_generator 0.1.0 Download meta_types_generator 0.1.0 archive
Describes how popular the package is relative to other packages. [more]
Code health derived from static analysis. [more]
Reflects how tidy and up-to-date the package is. [more]
Weighted score of the above. [more]
Learn more about scoring.

We analyzed this package on Dec 5, 2018, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.1.0
  • pana: 0.12.7


Detected platforms: other

Platform components identified in package: build, io, isolate, mirrors.

Health issues and suggestions

Document public APIs (-9.84 points)

61 out of 62 API elements (library, class, field or method) have no adequate dartdoc content. Good documentation improves code readability and discoverability through search.

Maintenance issues and suggestions

Homepage does not exists. (-20 points)

We were unable to access at the time of the analysis.

The description is too short. (-20 points)

Add more detail about the package, what it does and what is its target use case. Try to write at least 60 characters.


Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2-0-0-dev <3.0.0
analyzer ^0.32.0 0.32.6 0.34.0
build ^0.12.0 0.12.8 1.0.1
meta_types ^0.1.0 0.1.0
source_gen ^0.9.0 0.9.1+3
Transitive dependencies
args 1.5.1
async 2.0.8
charcode 1.1.2
collection 1.14.11
convert 2.0.2
crypto 2.0.6
csslib 0.14.6
dart_style 1.1.3 1.2.1
front_end 0.1.4+2 0.1.7
glob 1.1.7
html 0.13.3+3
kernel 0.3.4+2 0.3.7
logging 0.11.3+2
meta 1.1.6
package_config 1.0.5
path 1.6.2
plugin 0.2.0+3
source_span 1.4.1
string_scanner 1.0.4
typed_data 1.1.6
utf 0.9.0+5
watcher 0.9.7+10
yaml 2.1.15
Dev dependencies
build_runner ^0.9.0
build_test ^0.10.2
test ^1.0.0