PHP code example of apility / attribute-list

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

    

apility / attribute-list example snippets


use Apility\AttributeList\AttributeList;

$attributes = new AttributeList();
$attributes->addAttribute('class', 'button');
$attributes->addAttribute('loading', false);
$attributes->addAttribute('items', ['Item 1', 'Item 2', 'Item 3']);

echo "<vue-component {$attributes->toVuePropsString()}></vue-component>";