yiirocks / svg-inline
Inline SVG Images for Yii
Installs: 555
Dependents: 2
Suggesters: 0
Security: 0
Stars: 2
Watchers: 2
Forks: 0
Open Issues: 2
Type:yii3-extension
Requires
- php: >=7.4.0
- ext-dom: *
- yiisoft/aliases: ^2.0
- yiisoft/html: ^2.2
- yiisoft/yii-view: ^4.0
Requires (Dev)
- friendsofphp/php-cs-fixer: ^3.0
- httpsoft/http-message: ^1.0
- phpmd/phpmd: @stable
- phpunit/phpunit: ^9.0
- squizlabs/php_codesniffer: ^3.5
- vimeo/psalm: ^4.1
- yiirocks/svg-inline-bootstrap: ^1.0
- yiirocks/svg-inline-fontawesome: ^1.0
- yiisoft/config: ^1.0
- yiisoft/di: ^3.0
- yiisoft/files: ^1.0
- yiisoft/log: ^1.0
Suggests
- yiirocks/svg-inline-bootstrap: Bootstrap Icons are designed to work with Bootstrap components, from form controls to navigation.
- yiirocks/svg-inline-fontawesome: Get vector icons and social logos on your website with Font Awesome, the web's most popular icon set and toolkit.
This package is auto-updated.
Last update: 2024-12-13 12:37:53 UTC
README
inline
/ˈɪnlʌɪn/
adjectiveincluded as part of the main text on a page, rather than in a separate section
This extension provides simple functions for Yii framework 3.0 applications to add SVG Images inline.
Installation
The package could be installed via composer:
composer require yiirocks/svg-inline
It can be extended with Bootstrap Icons and/or Font Awesome Icons:
composer require yiirocks/svg-inline-bootstrap composer require yiirocks/svg-inline-fontawesome
Usage
The default configuration will enable $svg
in any view.
echo $svg->file('@assets/image.svg');
Available options can be found in the documentation.
Unit testing
The package is tested with PHPUnit. To run tests:
./vendor/bin/phpunit