PHPackages                             a2zwebltd/laravel-feature-voting - 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. a2zwebltd/laravel-feature-voting

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

a2zwebltd/laravel-feature-voting
================================

A portable Laravel engine for feature requests, voting, and status updates — with optional Blade and Livewire UI layers.

v1.0.0(1mo ago)052↓75%MITPHPPHP ^8.2CI failing

Since Apr 22Pushed 1mo agoCompare

[ Source](https://github.com/a2zwebltd/laravel-feature-voting)[ Packagist](https://packagist.org/packages/a2zwebltd/laravel-feature-voting)[ Docs](https://github.com/a2zwebltd/laravel-feature-voting)[ RSS](/packages/a2zwebltd-laravel-feature-voting/feed)WikiDiscussions main Synced 1w ago

READMEChangelog (1)Dependencies (6)Versions (2)Used By (0)

Laravel Feature Voting
======================

[](#laravel-feature-voting)

A portable Laravel engine for **feature requests, one-vote-per-user voting, and status updates** — with optional Blade and Livewire UI layers.

[![Packagist Version](https://camo.githubusercontent.com/39abce0d860487ba325efd1a6d7f731e6566dc611908d7b212d1b278f7ad7877/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f61327a7765626c74642f6c61726176656c2d666561747572652d766f74696e672e737667)](https://packagist.org/packages/a2zwebltd/laravel-feature-voting)[![PHP](https://camo.githubusercontent.com/b5d4f7901c58ad1ddfff679966f426cc25a9354bab763846b9a7276c2feab4e0/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d253545382e322d626c7565)](https://camo.githubusercontent.com/b5d4f7901c58ad1ddfff679966f426cc25a9354bab763846b9a7276c2feab4e0/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d253545382e322d626c7565)[![Laravel](https://camo.githubusercontent.com/ee7cca03cd9498dd9ab503e39be1a6c2d5d9f97a7737266a34cecba057a2fa3c/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c61726176656c2d313225323025374325323031332d626c7565)](https://camo.githubusercontent.com/ee7cca03cd9498dd9ab503e39be1a6c2d5d9f97a7737266a34cecba057a2fa3c/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c61726176656c2d313225323025374325323031332d626c7565)

Drop a feature-voting board into any Laravel app. Users submit ideas, vote (one vote per user, toggleable), and comment. Admins update the status (`under_review` → `planned` → `in_progress` → `completed` or `declined`) and submitters are emailed when it changes.

Three layers, each opt-in from the one below:

1. **Engine** — models, migrations, service, events, policies, mailables. Always works.
2. **HTTP + Blade** — controllers, routes, Tailwind-styled views. Works in any Laravel + Tailwind app.
3. **Livewire** — reactive vote button, inline commenting, sortable board. Auto-registers only when `livewire/livewire` is installed.

---

Features
--------

[](#features)

- ✅ One-vote-per-user enforced at the **database level** (unique index).
- ✅ Submission, voting (toggle), commenting — all through a single `FeatureVotingService`.
- ✅ Industry-standard status workflow: `under_review`, `planned`, `in_progress`, `completed`, `declined`.
- ✅ Admin response field on each request + styled admin comment thread.
- ✅ Email the configured admin on every new submission.
- ✅ Email the submitter every time the status changes — the "closed loop" that research shows is the #1 retention driver for feedback tools.
- ✅ Pluggable admin role — the consumer app defines a Gate; no hard-coded `is_admin` column.
- ✅ Events you can listen to: `FeatureRequestCreated`, `FeatureRequestVoted`, `FeatureRequestCommented`, `FeatureRequestStatusChanged`.
- ✅ Publishable config, migrations, views, and mail templates.
- ✅ Portable: no assumptions about the User model, theme, or UI library.

---

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

[](#requirements)

- PHP `^8.2`
- Laravel `^12.0 | ^13.0`
- Tailwind CSS in the consumer app (if using the shipped Blade views — not required if you build your own UI)
- `livewire/livewire` `^3.0 | ^4.0` (optional — only for the Livewire layer)

---

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

[](#installation)

```
composer require a2zwebltd/laravel-feature-voting
```

Publish and migrate:

```
php artisan vendor:publish --tag=feature-voting-config
php artisan vendor:publish --tag=feature-voting-migrations
php artisan migrate
```

Optionally publish the views if you want to restyle them:

```
php artisan vendor:publish --tag=feature-voting-views
```

---

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

[](#configuration)

`config/feature-voting.php`:

```
'admin_email' => env('FEATURE_VOTING_ADMIN_EMAIL'),
'admin_gate' => 'manage-feature-requests',
'routes' => [
    'enabled' => true,
    'prefix' => 'feature-requests',
    'middleware' => ['web', 'auth'],
],
'views' => [
    'layout' => 'feature-voting::layouts.default',  // point at your own layout
    'section' => 'content',
],
'livewire' => ['register' => true],
```

`.env`:

```
FEATURE_VOTING_ADMIN_EMAIL=admin@yourcompany.com

```

### Define who is an admin

[](#define-who-is-an-admin)

The package delegates the "is this user an admin?" decision to a Gate the consumer app defines:

```
// app/Providers/AppServiceProvider.php — boot()
use Illuminate\Support\Facades\Gate;
use App\Models\User;

Gate::define('manage-feature-requests', function (User $user) {
    return in_array($user->email, ['dawid@a2zweb.co']);
    // or $user->is_admin, or a role check, etc.
});
```

If no gate is registered, the package falls back to comparing `$user->email` to `config('feature-voting.admin_email')`. If neither is set, nobody is an admin (fail-closed).

### Point the views at your own layout

[](#point-the-views-at-your-own-layout)

The shipped pages extend a layout you control. In your published `config/feature-voting.php`:

```
'views' => [
    'layout' => 'layouts.app',   // your existing layout
    'section' => 'content',       // the @yield name inside it
],
```

---

Usage
-----

[](#usage)

### Drop-in: use the shipped pages

[](#drop-in-use-the-shipped-pages)

After install you get a working board at `/feature-requests`. Add a link from your app's nav:

```
Feature Requests
```

### Embed Blade components into your own pages

[](#embed-blade-components-into-your-own-pages)

```
                              {{-- full board --}}

           {{-- renders only for admins --}}
```

### Use the Livewire components

[](#use-the-livewire-components)

```

```

### Call the engine directly

[](#call-the-engine-directly)

```
use A2ZWeb\FeatureVoting\Services\FeatureVotingService;
use A2ZWeb\FeatureVoting\Enums\FeatureRequestStatus;

$service = app(FeatureVotingService::class);

$request = $service->submit($user, 'Add Slack export', 'Would love this');
$service->toggleVote($user, $request);
$service->comment($user, $request, 'Same here!');
$service->updateStatus($admin, $request, FeatureRequestStatus::Planned, 'Targeting Q3');
$service->isAdmin($user);
```

### Listen for events

[](#listen-for-events)

```
use A2ZWeb\FeatureVoting\Events\FeatureRequestCreated;
use Illuminate\Support\Facades\Event;

Event::listen(FeatureRequestCreated::class, function ($event) {
    // ping Slack, create a JIRA ticket, etc.
});
```

---

Data model
----------

[](#data-model)

`feature_requests` — `id`, `user_id` (nullable), `title`, `slug` unique, `description`, `status`, `votes_count`, `comments_count`, `admin_response`, `admin_responded_at`, `metadata` (json), timestamps, soft deletes.

`feature_request_votes` — `id`, `feature_request_id`, `user_id`, timestamps. **Unique `(feature_request_id, user_id)`**.

`feature_request_comments` — `id`, `feature_request_id`, `user_id` (nullable), `body`, `is_admin_response`, timestamps, soft deletes.

---

Disabling the HTTP layer
------------------------

[](#disabling-the-http-layer)

If you want to wire your own routes:

```
// config/feature-voting.php
'routes' => ['enabled' => false, /* ... */],
```

Then use the service directly and/or mount the Blade components into your own controllers.

---

Testing
-------

[](#testing)

```
composer install
vendor/bin/pest
```

---

Security Vulnerabilities
------------------------

[](#security-vulnerabilities)

If you discover a security vulnerability, please report it responsibly through private communication with the maintainers.

---

License
-------

[](#license)

MIT. See [LICENSE](LICENSE).

Credits
-------

[](#credits)

Developed and maintained by the **A2Z WEB** crew:

- [Dawid Makowski](https://github.com/makowskid)
- Website:
- GitHub:

###  Health Score

41

—

FairBetter than 87% of packages

Maintenance90

Actively maintained with recent releases

Popularity11

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity46

Maturing project, gaining track record

 Bus Factor1

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

48d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/2b500dd3d9b470b50b1ed911cd24a6fdcce51dd97dceb4f97879f727a14495a8?d=identicon)[dawid-makowski](/maintainers/dawid-makowski)

---

Top Contributors

[![makowskid](https://avatars.githubusercontent.com/u/6271194?v=4)](https://github.com/makowskid "makowskid (1 commits)")

---

Tags

laravelfeedbackvotingfeature-requestsfeature-votingroadmapproduct-feedback

###  Code Quality

TestsPest

Code StyleLaravel Pint

### Embed Badge

![Health badge](/badges/a2zwebltd-laravel-feature-voting/health.svg)

```
[![Health](https://phpackages.com/badges/a2zwebltd-laravel-feature-voting/health.svg)](https://phpackages.com/packages/a2zwebltd-laravel-feature-voting)
```

###  Alternatives

[markwalet/nova-modal-response

A Laravel Nova asset for Modal responses on an action.

17818.7k](/packages/markwalet-nova-modal-response)[joshcirre/instruckt-laravel

Visual feedback for AI coding agents — Laravel MCP package

17218.6k2](/packages/joshcirre-instruckt-laravel)[nickurt/laravel-akismet

Akismet for Laravel 11.x/12.x/13.x

98145.2k3](/packages/nickurt-laravel-akismet)[creasi/laravel-nusa

A Laravel package that aim to provide Indonesia' Administrative Data

987.7k2](/packages/creasi-laravel-nusa)[team-nifty-gmbh/tall-datatables

Server-side rendered datatables for Laravel and Livewire

1319.7k3](/packages/team-nifty-gmbh-tall-datatables)[tomshaw/electricgrid

A feature-rich Livewire package designed for projects that require dynamic, interactive data tables.

119.2k](/packages/tomshaw-electricgrid)

PHPackages © 2026

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