PHP code example of thesnackalicious / combinewords

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

    

thesnackalicious / combinewords example snippets


$ php artisan vendor:publish

$ php artisan tinker
>>> CombineWords::make('{color}{noun}');
=> "blackwood"

$ php artisan tinker
>>> CombineWords::uirements([new MaximumLengthRequirement(10), function($s) { return strpos($s, 'pink') === 0; }])->make('{color}{noun}');
=> "pinktree"