Post Link Component for Laravel
A simple package that provides a post-link component for Laravel. This component allows you to easily create links that, when clicked, will submit a form with a specified method (default is POST) and url. This is useful for creating links that delete or update resources, for example.
You can install the package via composer:
$ composer require salehhashemi1992/laravel-post-link
Once the package is installed, you can use the x-post-link component in your blade templates:
<x-post-link method="PUT" :url="route('notifications.mark-as-read', $notification->id)"
class="badge bg-danger rounded-pill float-end">
<i class="fe-x text-light"></i>
</x-post-link>
This will render a link that, when clicked, will submit a form with the method of "PUT" and the url of the mark-as-read action on the notifications controller with the notification id.
You can also pass a confirm attribute to the component, which will display a JavaScript confirm dialog before submitting the form.
Please see the changelog for more information on what has changed recently.
Please see contributing.md for details and a todolist.
If you discover any security related issues, please email salpars2004@gmail.com instead of using the issue tracker.
MIT. Please see the license file for more information.