Skip to content
CAI
Software that uses CAICheck a score

felangel/equatable

70.7

Strong · 19 September 2026

364

lines of production code

Dart

primary language

1

measurement over time

CAI band scale
CAI lens gauges

What this system is

This system is the Equatable library for Dart, which provides value-based equality and hashing for objects by comparing their properties. It supports modern Dart patterns through mixins and const constructors, and includes a global configuration system to control the string representation of instances. The codebase also contains performance benchmarks and comprehensive tests to ensure consistency across equality checks and hash code generation.

Features

Added benchmarks for equality comparison performance

A new benchmark suite has been added to measure the performance of equality comparisons using the \package:equatable\ library. The suite includes a \main.dart\ script that tests various scenarios, including empty, primitive, and collection-based equatable objects (static and dynamic, small/medium/large), and a \README.md\ documenting how to run the benchmarks and displaying baseline JIT and AOT results. The benchmarks are configured to use the local version of the \equatable\ package via \pubspec\_overrides.yaml\.

benchmarks · high confidence

Behavioural changes

Equatable now supports global stringify configuration via EquatableConfig

The library introduces \EquatableConfig\ to allow users to set a global default for the \stringify\ behavior, which controls whether \toString()\ outputs property values. This configuration defaults to \true\ in debug mode and \false\ in release mode, providing a convenient way to manage logging verbosity across all \Equatable\ instances without overriding \stringify\ on each class. The core \Equatable\ implementation has also been updated to use \EquatableConfig\ as the fallback when a specific instance's \stringify\ property is null, and equality comparisons now rely on utility functions for more robust handling of iterables and maps.

lib/src · high confidence

Updated example to demonstrate modern Equatable usage patterns

The example code has been updated to reflect current best practices for the Equatable package. The \Credentials\ class now uses the \with Equatable\ mixin syntax instead of extending \Equatable\, and its properties are declared as \const\ to enable compile-time constants. Additionally, a new \EquatableDateTime\ class is introduced to demonstrate mixing \Equatable\ with existing Dart types like \DateTime\, including the implementation of \props\ and \stringify\ overrides. These changes align the example with the deprecation of older patterns such as \EquatableMixin\.

example · high confidence

Test coverage

Expanded test coverage for Equatable equality, hashing, and stringify configuration

Added comprehensive tests for the Equatable library's core behaviors, including equality checks, hashCode consistency, and the \toString\ output. The new test suite verifies that instances with identical properties are considered equal and share the same hash code, while also covering edge cases such as empty props, nested iterables, and custom list implementations. Additionally, tests confirm that the global \EquatableConfig.stringify\ setting correctly controls string representation unless overridden at the instance level, and that the \EquatableMixin\ behaves consistently with the base \Equatable\ class in these scenarios.

test · high confidence

Dependencies

Equatable package upgraded to version 3.0.0 with Dart 3 SDK support

The core equatable package has been updated to version 3.0.0, raising the minimum supported Dart SDK version to 3.0.0. This release introduces new dependencies on the \collection\ and \meta\ packages, which are now required for the library's functionality. Additionally, the example application and benchmark suite have been updated to target newer Dart SDK versions (3.12.0 and 3.5.0 respectively) to align with these changes. The package metadata has also been refreshed with repository links, documentation URLs, and funding information.

(dependencies) · high confidence

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

How this codebase got here

Baseline

  • First survey — no prior run to compare against. CAI 71.

Lenses

  • Code Health 100
  • Architecture 100
  • Maturity 59
  • Readiness 59
  • Security 100
  • Domain Modelling 100

Changes since last survey

  • 138 commits — 116 feature/other, 22 fixes

By area

  • (root) — 92 commits
  • lib/src — 28 commits
  • benchmarks/README.md — 5 commits
  • .github/workflows — 3 commits
  • example/main.dart — 3 commits
  • doc/migration_guides — 2 commits
  • test/equatable_test.dart — 2 commits
  • (repo) — 1 commit
  • .github/FUNDING.yml — 1 commit
  • doc/assets — 1 commit

Notable commits

  • fix: #49: Fixed issue with empty lists (#53)
  • fix: Fix Map HashCode Collision (#44)
  • fix: Fix hashCode bug (#9)
  • fix: Increase minor version to release hashCode fix and toString feature (#56)
  • fix: fix analysis warnings
  • fix: fix test coverage
  • fix: fix!: avoid custom toString override (#218)
  • fix: fix!: do not test for runtimeType in object comparison (#219)
  • fix: fix: EquatableMixin should respect global stringify (#82)
  • fix: fix: mapEquals to correctly compare maps with different keys and null values (#207)
  • fix: fix: add @immutable to EquatableMixin (#154)
  • fix: fix: explicitly handle num equality comparisons (#189)
  • fix: fix: hashCode computation for Iterables (#76)
  • fix: fix: hashCode should be the same for equal objects (#118)
  • fix: fix: iterable equality comparisons (#103)
  • fix: fix: prop of type map with non-comparable key
  • fix: fix: props are not of type Comparable (#149)
  • fix: fix: revert EquatableMixin == to use Object (#122)
  • fix: fix: stringify instance with long properties (#97)
  • fix: fix: stringify null properties as "null" instead of "" (#93)
  • …and 118 more

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

Survey your own repository

felangel/equatable was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.

About this page

  • The score is its most recent published measurement, taken on 19 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
  • Measured at commit 832990678125b10103b26500ce8ce7188d775925 — the exact code this score is about.
  • Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
  • Measured by watchdog.canine.dev using codehealth-analyzer preprod-13a154b7f5d1.