Repository navigation
2.4.0 — Stricter relation detection, camelCase factory states
Generated output differs from previous versions; existing generated code is untouched. If you regenerate a factory, update calls to boolean states on snake_case columns (see below).
Changed
- Generated factory boolean states are camelCase:
is_publishednow givesisPublished()/
isNotPublished()instead ofis_published()/notIs_published(). Single-word columns keep
their names (enabled()/notEnabled()). The states usestatic fn (): arrayclosures and no
longer needphpcs:ignorecomments. - Pivot detection is stricter: a table counts as a
belongsToManypivot only when it holds just its
two foreign keys (plus optionalidand timestamps). Entity tables that reference two other tables
are no longer turned intobelongsToManyrelations. - Pivot table name and key columns are read from the detected schema instead of being derived from
naming conventions. - Generated models emit
#[Table]after#[Fillable](and after#[Appends]on admin users).
Fixed
#[Table(name: '...')]was HTML-escaped, producing invalid PHP for models whose table name does
not follow the convention.- Two blank lines between consecutive generated
hasManymethods.
Internal
AGENTS.md/CLAUDE.mdfor coding agents.- Request and permission generators resolve their template through a
$viewproperty. - New tests for relation detection, factory and model generation; snapshots regenerated.