79831682

Date: 2025-11-27 12:09:52
Score: 1.5
Natty:
Report link

you’re basically fighting 2 separate things here:

  1. how do i save multiple models at once? (backend)

  2. how do i not end up with a monster react component? (frontend)


1) backend – multiple models “in one go”

inertia vs livewire doesn’t matter here. once the request hits laravel it’s just:
“i got some nested data, i need to create/update a few models safely”.

the usual pattern:

so from laravel’s point of view it’s still just one form submit, just writing to 3–4 tables instead of 1. nothing inertia-specific about it.


2) frontend – avoid the god-component

this is where inertia + react shines if you structure it right.

core idea:

practically: you still have one form, one submit, one inertia post(), but visually and in code it feels like 3–4 smaller, focused components instead of one giant soup.


mental model that keeps things simple

doesn’t matter if you’re saving 1 model or 5 — same flow, just slightly more fields.

Reasons:
  • Blacklisted phrase (1): how do i
  • Blacklisted phrase (0.5): i need
  • Long answer (-1):
  • Has code block (-0.5):
  • Contains question mark (0.5):
  • Low reputation (1):
Posted by: Eli