Skip to content

Commit

Permalink
Merge pull request #694 from RomainMazB/patch-1
Browse files Browse the repository at this point in the history
Fix retrieving ziggys config from an api endpoint link in readme
  • Loading branch information
bakerkretzmar authored Dec 11, 2023
2 parents 125a990 + 25bf396 commit 7963d8d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -435,7 +435,7 @@ globalThis.Ziggy = Ziggy;

Ziggy's `route()` function is available as an NPM package, for use in JavaScript projects managed separately from their Laravel backend (i.e. without Composer or a `vendor` directory). You can install the NPM package with `npm install ziggy-js`.

To make your routes available on the frontend for this function to use, you can either run `php artisan ziggy:generate` and add the generated config file to your frontend project, or you can return Ziggy's config as JSON from an endpoint in your Laravel API (see [Retrieving Ziggy's config from an API endpoint](#retrieving-ziggys-routes-from-an-api-endpoint) below for an example of how to set this up).
To make your routes available on the frontend for this function to use, you can either run `php artisan ziggy:generate` and add the generated config file to your frontend project, or you can return Ziggy's config as JSON from an endpoint in your Laravel API (see [Retrieving Ziggy's config from an API endpoint](#retrieving-ziggys-config-from-an-api-endpoint) below for an example of how to set this up).

## Filtering Routes

Expand Down

0 comments on commit 7963d8d

Please sign in to comment.