PHP code example of slavawins / easyapi
1. Go to this page and download the library: Download slavawins/easyapi library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
slavawins / easyapi example snippets
php artisan vendor:publish --provider="EasyApi\Providers\EasyApiServiceProvider"
<x-easy-form route="{{route('product.buy', $product)}}" btn="Купить" onSuccess="EasyApi.UpdatePage">
@php
FElement::NewInputText()
->SetLabel("Количество")
->SetName("amount")
->SetValue(1)
->FrontendValidate()->Digital(1)
->SetPlaceholder("Сколько купить?")
->RenderHtml(true);
@endphp
</x-easy-form>