PHPackages                             muan/laravel-tags - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. muan/laravel-tags

ActivePackage[Utility &amp; Helpers](/categories/utility)

muan/laravel-tags
=================

Tags package for Laravel

0.1.0(7y ago)0291MITPHPPHP &gt;=7.0

Since May 4Pushed 7y ago1 watchersCompare

[ Source](https://github.com/mustardandrew/muan-laravel-tags)[ Packagist](https://packagist.org/packages/muan/laravel-tags)[ RSS](/packages/muan-laravel-tags/feed)WikiDiscussions master Synced 2d ago

READMEChangelogDependenciesVersions (2)Used By (1)

Maun Laravel Tags package
=========================

[](#maun-laravel-tags-package)

[![Maintainability](https://camo.githubusercontent.com/0b488f7e09bc5e736e5bcf33796490780be1632a03129b691fe755d37601c70e/68747470733a2f2f6170692e636f6465636c696d6174652e636f6d2f76312f6261646765732f65613564373532313934646264613866663161632f6d61696e7461696e6162696c697479)](https://codeclimate.com/github/mustardandrew/muan-laravel-tags/maintainability)

Used for create tags.

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

[](#requirements)

- "php": "&gt;=7.0"

Install
-------

[](#install)

1. Type next command in your terminal:

```
composer require muan/laravel-tags
```

2. Add the service provider to your config/app.php file in section providers:

> Laravel 5.5 uses Package Auto-Discovery, so does not require you to manually add the ServiceProvider.

```
'providers' => [
    // ...
    Muan\Tags\Providers\TagsServiceProvider::class,
    // ...
],
```

3. Use the following trait on your model

```
// Use trait
use Muan\Tags\Traits\Taggable;

class Post extends Model
{
    use Taggable;

    // ...
}
```

Usage (examples)
----------------

[](#usage-examples)

### Create &amp; attach single tag

[](#create--attach-single-tag)

```
// Create tag
$tag = Muan\Tags\Model\Tag::create([
    'title' => $title = 'Laravel',
    'slug' => str_slug($title)
]);

// Attach tag
$post = App\Post::find(1);
$post->tags()->attach($tag->id);
```

### Create &amp; attach multiple tags

[](#create--attach-multiple-tags)

```
$tags = ['Laravel', 'Eloquent', 'Tags'];

foreach ($tags as $index => $tag) {
    $preparedTag = [
        'title' => $tag,
        'slug' => str_slug($tag)
    ];

    $tagId = Muan\Tags\Model\Tag::create($prepareTag)->id;
    $tags[$index] = $tagId;
}

$post = App\Post::find($id = 1);
$post->tags()->sync($tags);
```

### Get tags

[](#get-tags)

```
$tags = App\Post::find(1)->tags;
```

### Commands

[](#commands)

Create new tag

```
// Slug is generated automatically using str_slug()

php artisan tag:create "tag title"
```

License
-------

[](#license)

Muan Laravel Admin package is licensed under the [MIT License](http://opensource.org/licenses/MIT).

###  Health Score

22

—

LowBetter than 22% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity44

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 75% 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

2567d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/c5d692559a8730e2167796208810140710f1f4842700cd99ec11508cbdee99e3?d=identicon)[mustardandrew](/maintainers/mustardandrew)

---

Top Contributors

[![mustardandrew](https://avatars.githubusercontent.com/u/7501643?v=4)](https://github.com/mustardandrew "mustardandrew (3 commits)")[![qWici](https://avatars.githubusercontent.com/u/11472929?v=4)](https://github.com/qWici "qWici (1 commits)")

---

Tags

laravelpackagemessagescomments

### Embed Badge

![Health badge](/badges/muan-laravel-tags/health.svg)

```
[![Health](https://phpackages.com/badges/muan-laravel-tags/health.svg)](https://phpackages.com/packages/muan-laravel-tags)
```

###  Alternatives

[tizis/lara-comments

Comments system for your Laravel application. Features: can be used to comment on any model, HTML filter customization (HTMLPurifier), API, comment rating, replies, events, auth rules ...

1194.7k](/packages/tizis-lara-comments)[wujunze/money-wrapper

MoneyPHP Wrapper

113.8k](/packages/wujunze-money-wrapper)

PHPackages © 2026

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