-
Notifications
You must be signed in to change notification settings - Fork 0
Home
This library is an InertiaJS Adapter for PHP projects that uses implementation of PSR7 (HTTP Message Interface), PSR15 (Server Request Handlers), and optionally PSR11 (Container Interface).
Install library using composer command:
$ composer require thewebsolver/inertia
This adapter comes with its own middleware that prepares the response header needed to convert the current Server request to an Inertia request. To do this, you need to follow the approach where middleware response headers are kept and sent to the next middleware.
This requirement is mandatory because when the ::handle()
method of the Request Handler returns a response, it must include the headers of the Inertia Middleware's response. To achieve this, you may need to utilize the Pipeline library in your request handler. For more details, refer to the Pipeline Wiki Page.
$ composer require thewebsolver/pipeline