Lets imagine that we need to handle an api public key, Laravel by default ships with an
env file to set this types of properties, there are times where these values should be access from the backend and from the frontend site.
Of course with InertiaJS we can set a value with key and value in the
HandleInertiaRequest middleware, but it would be much cleaner to directly call these values from the
ENV file through the code.
Lets set an api public key as an example:
Hope it helps, Happy Coding!
Latest comments (0)