Skip to content

Helper class for generating attribute lists for markup

License

Notifications You must be signed in to change notification settings

apility/attribute-list

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

AttributeList

AttributeList is a helper class for generating attribute lists for markup.

License: Beerware Version CircleCI

Documentation

Installation

Use the package manager Composer to install AttributeList.

composer require apility/attribute-list

Usage

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>";

License

Beerware License

cathrine.vaage@gmail.com wrote this file. As long as you retain this notice you can do whatever you want with this stuff. If we meet some day, and you think this stuff is worth it, you can buy me a beer in return.

About

Helper class for generating attribute lists for markup

Topics

Resources

License

Contributing

Stars

Watchers

Forks

Packages

No packages published

Contributors 3

  •  
  •  
  •  

Languages