PHP code example of performing / laravel-harmony

1. Go to this page and download the library: Download performing/laravel-harmony 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/ */

    

performing / laravel-harmony example snippets


use Performing\Harmony\Page;
use Performing\Harmony\Components\TableComponent;

class ModelController 
{
    public function index() : Inertia\Response
    {
        return [
            Page::make('Title')
                ->table(
                    TableComponent::make()
                        ->rows(Model::query())
                        ->columns([ ... ])
                        ->filters([ ... ])
                        ->selectable()
                )
                ->render('harmony::resources/index')
        ]
    }
}
bash
php artisan vendor:publish --tag="harmony-config"