PackageTrack
Sign in Get early access

built_value_generator

Value types with builders, Dart classes as enums, and serialization. This library is the dev dependency.

8.12.7 342K downloads/mo #636 most downloaded on pub.dev google/built_value.dart

What this package is like to depend on

Last release 19 days ago

05 Aug 2026

Ships fairly regularly

a new release about every 5 weeks

Most releases are documented

notes for 103 of 160 stable releases

Nothing withdrawn

no release was ever pulled

11 years old

162 releases · first in 2015

9 releases in the last 12 months

see the full history below

Release timeline

162 releases · Oct 2015 to Aug 2026
2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026
Release Pre-release

Releases

latest 60 of 162
  1. 8.12.7 05 Aug 2026
    Release notes
    • Allow analyzer 13.0.0 and analyzer 14.0.0
    Open source →
  2. 8.12.6 30 Apr 2026
    Release notes
    • Require analyzer 13.0.0.
    Open source →
  3. 8.12.5 25 Mar 2026
    Release notes
    • Allow analyzer 11.0.0 and analyzer 12.0.0.
    Open source →
  4. 8.12.4 20 Feb 2026
    Release notes
    • Reduce use of dynamic calls in generated operator== when there are functions: only use dynamic calls if the class also has type parameters.
    Open source →
  5. 8.12.3 15 Jan 2026
    Release notes
    • Require analyzer ^10.0.0, stop using removed and deprecated methods from earlier versions.
    Open source →
  6. 8.12.2 13 Jan 2026
    Release notes
    • Allow analyzer 10.0.0.
    Open source →
  7. 8.12.1 21 Nov 2025
    Release notes
    • Allow analyzer 9.0.0.
    Open source →
  8. 8.12.0 05 Sep 2025
    Release notes
    • Enable build_runner 2.7.0 "triggers" optimization.
    • built_value will now only run in libraries that directly import package:built_value/built_value.dart or use an annotation called @SerializersFor. Other files will be quickly skipped and show in build_runner output as "not triggered" or "skipped".
    • If you need to run built_value on other source files, see https://pub.dev/packages/build_config#triggers for how to configure your own additional triggers for built_value.
    Open source →
  9. 8.11.2 04 Sep 2025
    Release notes
    • Require analyzer ^8.0.0.
    • Allow built_value_generator to use build 4.0.0.
    • Allow built_value_generator to use source_gen 4.0.0.
    Open source →
  10. 8.11.1 06 Aug 2025
    Release notes
    • Allow built_value_generator to use analyzer 8.0.0.
    Open source →
  11. 8.11.0 18 Jul 2025
    Release notes
    • Use build ^3.0.0.
    • Use source_gen ^3.0.0.
    Open source →
  12. 8.11.0-dev 08 Jul 2025 pre-release
    Release notes
    • Use build ^3.0.0-dev.
    • Use source_gen ^3.0.0-dev.
    Open source →
  13. 8.10.1 28 May 2025
    Release notes
    • Add mutable collection serializers so built_value can serialize List, Set and Map. It's still recommended to avoid mutable collections inside value types as they break hashing, comparison and caching; the intended use case is that you have one top level mutable collection of your immutable value types.
    Open source →
  14. 8.10.0 27 May 2025
    Release notes
    • Stop generating unnecessary new keywords.
    • Stop generating explicit null checks in constructors: these are not needed with sound null safety.
    • Stop generating checks for dynamic in generics in constructors: accidental use of dynamic is better avoided with lints than a runtime check.
    Open source →
  15. 8.9.5 06 Mar 2025
    Release notes
    • Allow built_value_generator to use analyzer 7.0.0.
    Open source →
  16. 8.9.4 26 Feb 2025
    Release notes
    • Allow built_value_generator to use source_gen 2.0.0.
    Open source →
  17. 8.9.3 18 Dec 2024
    Release notes
    • Generate code that formats faster with current "short" style. Both versions are fast with the coming "tall" style.
    • Mark @nullable deprecated: it does nothing and should not be used.
    Open source →
  18. 8.9.2 03 Apr 2024
    Release notes
    • Improve build performance when there are lots of built_value classes.
    Open source →
  19. 8.9.1 19 Feb 2024
    Release notes
    • Fix for new warning about operator== param type.
    Open source →
  20. 8.9.0 24 Jan 2024
    Release notes
    • In StandardJsonPlugin, add support for specifying types that should be left as List.
    • Allow non alphanumeric characters in EnumClass names.
    Open source →
  21. 8.8.1 12 Dec 2023
    Release notes
    • Fix codegen for enum wire keys when there is a $ in the field name.
    • Remove support for generating legacy (<2.12) Dart code.
    Open source →
  22. 8.8.0 24 Nov 2023
    Release notes
    • Allow classes with record fields to be serialized if they use a typedef for the record type and install a custom Serializer for it.
    Open source →
  23. 8.7.0 30 Oct 2023
    Release notes
    • Add Int32 serializer.
    Open source →
  24. 8.6.3 21 Sep 2023
    Release notes
    • Bump version of analyzer.
    Open source →
  25. 8.6.2 24 Aug 2023
    Release notes
    • Remove JSON from DeserializationError message to prevent data accidentally leaking into logs. The JSON is still available on the DeserializationError object.
    • Fix generation for fields that are Function types that are declared separately, for example in a mixin defined in another source file, and use named or positional parameters.
    Open source →
  26. 8.6.1 05 Jun 2023
    Release notes
    • Fix support for generating enum mixins for Dart 3. Instead of triggering mixin generation with abstract class TestEnumMixin = Object with _$TestEnumMixin it must now be triggered with typedef TestEnumMixin = _$TestEnumMixin.
    Open source →
  27. 8.6.0 22 May 2023
    Release notes
    • Add support for value types with record fields. Serialization with records is not yet supported.
    • Fix generator failure due to top level record field.
    • Migrate benchmark and examples to null safety.
    • Remove pre-null-safe test cases.
    • Remove analyzer plugin.
    • Remove reference to @nullable annotation from failure-to-instantiate message.
    Open source →
  28. 8.5.0 03 May 2023
    Release notes
    • Add Uint8ListSerializer.
    • Generate Dart-3-compatible code if needed.
    • Stop using deprecated analyzer API.
    • Fix codegen for optional fields with $ in the name.
    Open source →
  29. 8.4.4 03 Mar 2023
    Release notes
    • Increase minimum version of analyzer.
    • Fix generation with the type Never.
    Open source →
  30. 8.4.3 11 Jan 2023
    Release notes
    • Fix generated deserialization code when there is a manually written builder with nullable fields.
    • Drop dev dependency on quiver.
    • Disable all linting of generated code.
    • Change generated hash code implementation so it formats better when there are many fields.
    Open source →
  31. 8.4.2 27 Oct 2022
    Release notes
    • Prepare for breaking analyzer changes.
    • Bump version of analyzer.
    Open source →
  32. 8.4.1 19 Aug 2022
    Release notes
    • Bump version of analyzer.
    Open source →
  33. 8.4.0 13 Jul 2022
    Release notes
    • Fix custom builders in null safe code: allow nested builder fields to be nullable.
    • Improve custom builders for null safe code: allow abstract setter/getter pairs instead of fields. This allows nested builders to have a setter that accepts null and a getter that guarantees not to return null, which is what auto instantiation of nested builders already provides.
    • Allow use of super field initialization in EnumClass.
    Open source →
  34. 8.3.3 17 Jun 2022
    Release notes
    • Fix erroneously generated null check for fields with generic bounds.
    Open source →
  35. 8.3.2 24 May 2022
    Release notes
    • Migrate built_value_test to null safety.
    Open source →
  36. 8.3.1 24 May 2022
    Release notes
    • Fix generation support for optional generic bounds, e.g. class Foo<T extends Object?>.
    • Fix generation for classes with names starting $.
    • Ignore lint unnecessary_lambdas in generated code.
    Open source →
  37. 8.3.0 10 May 2022
    Release notes
    • Change generated build methods to return only public types, creating _build methods that return the generated impl types. This means dartdoc will no longer reference the generated types.
    • Ignore the no_leading_underscores_for_local_identifiers lint in generated code.
    • Migrated built_value_generator to null safety. This is purely an internal change, the generator can still generate legacy code as and when needed.
    Open source →
  38. 8.2.3 27 Apr 2022
    Release notes
    • Bug fix: fix a corner case with generics that had incorrect serializer generation.
    Open source →
  39. 8.2.2 27 Apr 2022
    Release notes
    • Bug fix: remove a print from the enum generator.
    Open source →
  40. 8.2.1 26 Apr 2022
    Release notes
    • Fix deps: allow built_value_generator to use built_value 8.2.0.
    Open source →
  41. 8.2.0 15 Apr 2022
    Release notes
    • Allow writing final parameters in EnumClass constructor and valueOf method.
    • Make generator output additional explicit null checks so the generated code complies with the cast_nullable_to_non_nullable lint.
    • Bump version of analyzer.
    Open source →
  42. 8.1.4 14 Jan 2022
    Release notes
    • Bump version of analyzer.
    Open source →
  43. 8.1.3 28 Oct 2021
    Release notes
    • Bump version of analyzer, fix deprecation warnings.
    Open source →
  44. 8.1.2 09 Aug 2021
    Release notes
    • Bump version of analyzer.
    Open source →
  45. 8.1.1 09 Jul 2021
    Release notes
    • Bug fix: allow constructors to have annotations. Previously, annotations would cause codegen to fail.
    Open source →
  46. 8.1.0 18 Jun 2021
    Release notes

    New features:

    • Add @BuiltValueHook annotation. It provides the same functionality as _initializeBuilder and _finalizeBuilder, but in a more visible way: annotate a static method on the value class with @BuiltValueHook to have it called on builder creation or finalization.
    • Add back serializeNulls to BuiltValueSerializer annotation. By default generated serializers skip null fields instead of writing them; set serializeNulls to write the nulls.

    New minor functionality:

    • Support use of nulls in collections when the key or value types are explicitly nullable.
    • Allow JsonObject to be instantiated from a Map<dynamic, dynamic>.
    • Mark nested builder getters in instantiable: false classes not nullable, to match the implementations. Use autoCreateNestedBuilders: false to get the old behaviour.
    • Allow explicit nulls in JSON for nullable fields when deserializing.
    • Specify annotation targets; the analyzer will now hint if a built_value annotation is used where it has no effect.
    • Support polymorphism with mixed in parent value type: generated builder now mixes in parent builder.

    Bug fixes:

    • Fix support for serializing and deserializing nulls.
    • Fix nestedBuilders: false with instantiable: false.
    • Fix enum deserialization fallback for int.
    • Annotating a wrong type getter with @SerializersFor is now an error, instead of just generating nothing.

    Cleanup:

    • Removed Angular mixin from example, as this feature is no longer needed: Angular now directly supports using static members in templates.
    Open source →
  47. 8.0.6 06 May 2021
    Release notes
    • Bump versions of build_config and build_runner.
    Open source →
  48. 8.0.5 22 Apr 2021
    Release notes
    • Bump version of analyzer.
    Open source →
  49. 8.0.4 22 Mar 2021
    Release notes
    • Bump version of source_gen.
    Open source →
  50. 8.0.3 17 Mar 2021
    Release notes
    • Fix error message for builder factory not installed.
    • Bump version of build.
    Open source →
  51. 8.0.2 09 Mar 2021
    Release notes
    • Bump versions of analyzer, quiver.
    Open source →
  52. 8.0.1 09 Mar 2021
    Release notes
    • Update chat example to webdev.
    • Allow nulls when serializing/deserializing for better JSON interop.
    • Fix generation bugs around enum wire name and polymorphism.
    • Fix generation with generics for analysis with strict-raw-types.
    • Add test coverage around generation for generic serialization.
    • Add test coverage around initialization with generics.
    Open source →
  53. 8.0.0 09 Feb 2021
    Release notes
    • Stable null safe release.
    • Add toJson and fromJson convenience methods to Serializers.
    Open source →
  54. 8.0.0-nullsafety.0 19 Jan 2021 pre-release
    Release notes
    • Migrate to NNBD.
    • Remove dependency on package:quiver.
    • Remove support for serializing nulls using BuiltValueSerializer(serializeNulls: true).
    • Make installed plugins public in Serializers as serializerPlugins.
    • @memoized fields can now memoize null; previously, nulls would not be cached, causing the computation to rerun.
    Open source →
  55. 7.1.1 26 Aug 2021
    Release notes
    • Support analyzer ^0.40.0.
    • Workaround https://github.com/google/built_value.dart/issues/941.
    Open source →
  56. 7.1.0 23 Apr 2020
    Release notes
    • Support private Built classes. Note that private classes cannot be made serializable.
    • Support serializing enums to ints: add wireNumber to @BuiltValueEnumConst.
    • Support memoizing hashCode, so it's computed lazily once. Write an abstract getter int get hashCode; then annotate it with @memoized to turn this on for a built_value class.
    • Trim built_value_test dependencies: depend on matcher instead of test.
    • Fix enum generator error messages when value and valueOf are missing.
    Open source →
  57. 7.0.9 07 Feb 2020
    Release notes
    • Fix unescaped string usages while generating ValueSourceClass.
    • Fix analyzer use: don't rely on toString on types.
    Open source →
  58. 7.0.8 16 Jan 2020
    Release notes
    • Fix analyzer lower bound: was 0.39.0, needs to be 0.39.3.
    Open source →
  59. 7.0.7 16 Jan 2020
    Release notes
    • Fix regression in a corner case when determining which fields to generate based on mixins.
    • Tweak generation changes for implicit-casts: false and implicit-dynamic: false. Relax casts again where possible.
    Open source →
  60. 7.0.6 15 Jan 2020
    Release notes
    • Make generated code comply with analyzer option strict-raw-types.
    • Allow Serialiers declaration to comply with strict-raw-types, or to continue to use raw types as before.
    • Make generated code comply with analyzer options implicit-casts: false and implicit-dynamic: false.
    Open source →

Every package, every release, already written down.

The archive is open and free. Watching your own project is what we are building next.

Browse the archive