PHP code example of jbernavaprah / lighthouse-translation

1. Go to this page and download the library: Download jbernavaprah/lighthouse-translation 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/ */

    

jbernavaprah / lighthouse-translation example snippets



use JBernavaPrah\UseTranslation ;
use Illuminate\Database\Eloquent\Model;

/**
 * @property \JBernavaPrah\LighthouseTranslation\Translate $name
 * 
 */
class Item extends Model 
{
    use UseTranslation;
    
    public function translationColumns(): array{
        return ["name"]
    }
    
    
}