wongyip/html-icons

HTMl Icons

Installs: 398

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 1

Forks: 0

Open Issues: 0

pkg:composer/wongyip/html-icons

v0.1.1 2024-10-22 06:07 UTC

This package is auto-updated.

Last update: 2025-09-22 07:58:33 UTC


README

  • Early stage of development, use with care.
  • Developed with initial support of FontAwesome 6 icons pack.
  • Extensible to support other icons font pack.

Usage (default, FontAwesome icons)

PHP:

echo
    implode("\n", [
        Icon::make('ufo')->render(),
        Icon::make('ufo')->duotone()->render(),
        Icon::make('ufo')->flipVertical()->render(),
        Icon::make('ufo')->fixedWidth()->render(),
        Icon::make('ufo')->size(5)->render(),
        Icon::make('ufo')->duotone()->flipVertical()->fixedWidth()->size(5)->render(),
    ]);

Output:

<i class="fa-regular fa-ufo" aria-hidden="true">&zwnj;</i>
<i class="fa-duotone fa-ufo" aria-hidden="true">&zwnj;</i>
<i class="fa-regular fa-ufo fa-flip-vertical" aria-hidden="true">&zwnj;</i>
<i class="fa-regular fa-ufo fa-fw" aria-hidden="true">&zwnj;</i>
<i class="fa-regular fa-ufo fa-5x" aria-hidden="true">&zwnj;</i>
<i class="fa-duotone fa-ufo fa-5x fa-flip-vertical fa-fw" aria-hidden="true">&zwnj;</i>