title: Inertia.js and Laravel: How does pagination state work?
body: <p>I am using the demo app PingCRM to learn how Inertia.js works.</p>
  <p>When a user clicks on a main menu item, such as Organizations or Contacts, an XHR is sent to the corresponding URL, either <code>/organizations</code> or <code>/contacts</code>, as expected.  If I use the pagination links at the bottom of a page, they send requests such as <code>/contacts?page=1</code>, <code>/contacts?page=2</code>, as expected.</p>
  <p>If I navigate away from that section though, then navigate back, somehow the server knows which page I was up to and it returns a redirect.  For example, if I am browsing <code>/contacts?page=3</code>, then I select the main menu item Organizations, it requests <code>/organizations</code> (as expected).  When I next select Contacts however, it sends a <code>/contacts</code> (as expected), but receives a 302 with the location set to <code>/contacts?page=3</code>.</p>
  <p>How does this feature work?  Is the Laravel session storing my state, and is this part of the Inertia back end adapter?  Or is the state stored in the browser and passed to the server in a cookie?  Where can I find details of this in the Intertia.js documentation?  (The section on Local State seems to relate more to browser history).</p>
  <p>I notice that a similar scenario exists when you filter organizations.  If you navigate away from the page while a filter is in use, then return to the page, a request to <code>/organizations</code> received a 302, with a location of <code>/organizations?search=abc</code>.</p>