Skip to content

v0.38.0 — ORM maturity

Choose a tag to compare

@tshafer tshafer released this 11 Jul 06:17
· 123 commits to main since this release

Rounds out the active-record ORM toward Lucid/Eloquent parity.

  • Timestampsstatic timestamps = true auto-manages created_at / updated_at (both on insert, only updated_at on update); column names overridable.
  • PaginationModel.paginate(page, perPage) and db(table).paginate(...) return Paginated<T> (data, total, perPage, currentPage, lastPage).
  • Aggregates & single valuessum / avg / min / max, plus value(column) and pluck(column).
  • More query clauseswhereBetween, whereNotIn, whereLike, latest() / oldest().
  • Find-or-create & convenience writesfirstOrCreate, updateOrCreate, instance update(attrs) and refresh().

207 tests; type-checked doc examples.