silbinarywolf / silverstripe-components
Create components using SilverStripe.
Installs: 649
Dependents: 0
Suggesters: 0
Security: 0
Stars: 7
Watchers: 3
Forks: 2
Type:silverstripe-vendormodule
Requires
- php: >=5.4
- silverstripe/framework: ~4.0
Requires (Dev)
- phpunit/phpunit: ^5.7
- squizlabs/php_codesniffer: ^3.0
Replaces
- 3.2.1
- 3.2.0
- dev-master / 3.1.x-dev
- 3.1.0
- 3.0.x-dev
- 3.0.0
- 2.2.1
- 2.2.0
- 2.1.1
- 2.1.0
- 2.0.1
- 2.0.0
- 1.x-dev
- 1.3.x-dev
- 1.3.0
- 1.2.x-dev
- 1.2.1
- 1.2.0
- 1.1.x-dev
- 1.1.2
- 1.1.1
- 1.1.0
- 1.0.x-dev
- 1.0.2
- 1.0.1
- 1.0.0
- 0.4.1
- 0.4.0
- 0.3.1
- 0.3.0
- 0.2.0
- 0.1.0
- dev-fix-children
- dev-fix-dbcomponent-field
- dev-feature-json-nested
- dev-fix-ss4-json-escaping
- dev-fix-ss3-json-single-quote
- dev-feat-ss3-json-data
- dev-feature-ss4-json-syntax
This package is not auto-updated.
Last update: 2022-02-01 13:12:43 UTC
README
This module allows you to use special <:TemplateName> syntax to include templates. This allows you to pass inner HTML into a template, much like you can do in React with the children properties. Using the <:TemplateName> syntax will not automatically pass variables in the current scope like <% include %>.
<:MyButtonTemplate
icon="fa fa-icon"
title="$Title"
>
<span class="text">
Look at me! Passing HTML in here!
</span>
</:MyButtonTemplate>
<:SelfClosingTag passvariable="hey" />
Composer Install
composer require symbiote/silverstripe-components:~1.0
composer require symbiote/silverstripe-components:~3.0
Requirements
- PHP 5.6+
- SilverStripe 4.0+
Documentation
Credits
- Cam Spiers for his SilverStripe Compose Parser module. This utilizes and builds upon his work from half a decade ago!