PHPackages                             marvinrabe/blade-flags - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Templating &amp; Views](/categories/templating)
4. /
5. marvinrabe/blade-flags

ActiveLibrary[Templating &amp; Views](/categories/templating)

marvinrabe/blade-flags
======================

A package to easily make use of country flags in your Laravel Blade views.

7.5.0(3mo ago)0382↓40%MITPHPPHP ^8.0CI passing

Since Feb 12Pushed 3mo agoCompare

[ Source](https://github.com/marvinrabe/blade-flags)[ Packagist](https://packagist.org/packages/marvinrabe/blade-flags)[ Docs](https://github.com/marvinrabe/blade-flags)[ GitHub Sponsors](https://github.com/marvinrabe)[ RSS](/packages/marvinrabe-blade-flags/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependencies (4)Versions (2)Used By (0)

Blade Flags
===========

[](#blade-flags)

[![Latest Version on Packagist](https://camo.githubusercontent.com/573760dbea2fef46b6170607cb8e5d7c1556542169bb873f34cceef5f7e89632/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6d617276696e726162652f626c6164652d666c6167732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/marvinrabe/blade-flags)[![GitHub Tests Action Status](https://camo.githubusercontent.com/5be8138cfff4c0e8a19cf7455cbf9a616d562482e454a8e8bf54ad8e758ab68d/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f6d617276696e726162652f626c6164652d666c6167732f72756e2d74657374732e796d6c3f6272616e63683d6d61696e)](https://github.com/marvinrabe/blade-flags/actions?query=workflow%3ATests+branch%3Amain)[![Total Downloads](https://camo.githubusercontent.com/0288b371ebfa07bbb414059fc27259a4b703b08e870d8402d1d8b6a6168ec6f7/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6d617276696e726162652f626c6164652d666c6167732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/marvinrabe/blade-flags)

A package to easily make use of country flags in your Laravel Blade views.

For a full list of available flags see [the SVG directory](resources/svg) or preview them at [flag-icons](https://flagicons.lipis.dev/). Flag SVGs are provided by [lipis/flag-icons](https://github.com/lipis/flag-icons).

Requirements
------------

[](#requirements)

- PHP 8.0 or higher
- Laravel 9.0 or higher

Installation
------------

[](#installation)

```
composer require marvinrabe/blade-flags
```

Blade Icons
-----------

[](#blade-icons)

Blade Flags uses Blade Icons under the hood. Please refer to [the Blade Icons readme](https://github.com/blade-ui-kit/blade-icons) for additional functionality. We also recommend to [enable icon caching](https://github.com/blade-ui-kit/blade-icons#caching) with this library.

Configuration
-------------

[](#configuration)

Blade Flags also offers the ability to use features from Blade Icons like default classes, default attributes, etc. If you'd like to configure these, publish the `blade-flags.php` config file:

```
php artisan vendor:publish --tag=blade-flags-config
```

Usage
-----

[](#usage)

Icons can be used as self-closing Blade components which will be compiled to SVG icons:

```

```

You can also pass classes to your icon components:

```

```

And even use inline styles:

```

```

Or use the `@svg` directive:

```
@svg('flag-4x3-us', 'w-6 h-6', ['style' => 'color: #555'])
```

Flags are available in two aspect ratios. The 4x3 flags:

```

```

And the 1x1 (square) flags:

```

```

### Raw SVG Icons

[](#raw-svg-icons)

If you want to use the raw SVG icons as assets, you can publish them using:

```
php artisan vendor:publish --tag=blade-flags --force
```

Then use them in your views like:

```

```

Credits
-------

[](#credits)

- Project structure based on [blade-ui-kit/blade-heroicons](https://github.com/blade-ui-kit/blade-heroicons) by [Dries Vints](https://driesvints.com)
- Flag SVGs from [lipis/flag-icons](https://github.com/lipis/flag-icons)

License
-------

[](#license)

Blade Flags is open-sourced software licensed under [the MIT license](LICENSE.md).

###  Health Score

39

—

LowBetter than 86% of packages

Maintenance82

Actively maintained with recent releases

Popularity17

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity39

Early-stage or recently created project

 Bus Factor1

Top contributor holds 66.7% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

95d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/515860?v=4)[Marvin Rabe](/maintainers/marvinrabe)[@marvinrabe](https://github.com/marvinrabe)

---

Top Contributors

[![marvinrabe](https://avatars.githubusercontent.com/u/515860?v=4)](https://github.com/marvinrabe "marvinrabe (2 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (1 commits)")

---

Tags

laravelbladeflags

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/marvinrabe-blade-flags/health.svg)

```
[![Health](https://phpackages.com/badges/marvinrabe-blade-flags/health.svg)](https://phpackages.com/packages/marvinrabe-blade-flags)
```

###  Alternatives

[outhebox/blade-flags

A package to easily make use of country &amp; language flags in your Laravel Blade views.

303723.7k6](/packages/outhebox-blade-flags)[stijnvanouplines/blade-country-flags

A package to easily make use of country flags in your Laravel Blade views.

26307.2k6](/packages/stijnvanouplines-blade-country-flags)[technikermathe/blade-lucide-icons

A package to easily make use of Lucide icons in your Laravel Blade views.

18299.2k7](/packages/technikermathe-blade-lucide-icons)[saade/blade-iconsax

A package to easily make use of Iconsax in your Laravel Blade views.

21138.5k](/packages/saade-blade-iconsax)[mckenziearts/blade-untitledui-icons

A package to easily make use of UntitledUI icons in your Laravel Blade views.

16104.9k5](/packages/mckenziearts-blade-untitledui-icons)[afatmustafa/blade-hugeicons

A package to easily make use of Hugeicons(Free version) in your Laravel Blade views.

13129.0k3](/packages/afatmustafa-blade-hugeicons)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
