PHP code example of temper / laravel-nullable-properties

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

    

temper / laravel-nullable-properties example snippets


$this->property = $request->get('property');

$this->fill($request->all());



use Illuminate\Database\Eloquent\Model;
use Temper\NullableProperties\NullableProperties;

class User extends Model {
    use NullableProperties;

    public $nullable = ['favoriteColor'];
};