vigstudio/livewire-comments
Livewire-powered comment system for Laravel: attach comments to any model, run multiple comment widgets per page, support multiple auth guards, file/image uploads (drag & drop/paste), reCAPTCHA v3, emojis, Markdown, NSFW image checks, plus Echo updates.
| Criteria | vigstudio/livewire-comments | Custom Build | Disqus/Embedded | Laravel Nova Comments |
|---|---|---|---|---|
| Real-time updates | ✅ (Livewire) | ⚠️ (Depends on JS) | ✅ (Disqus) | ❌ |
| Multi-auth guard | ✅ | ✅ | ❌ | ❌ |
| Media uploads | ✅ (Drag-and-drop) | ✅ | ✅ | ❌ |
| NSFW filtering | ✅ | ⚠️ (Manual) | ❌ | ❌ |
| Markdown/emoji | ✅ | ✅ | ❌ | ❌ |
| Guest comments | ⚠️ (Partial) | ✅ | ✅ | ❌ |
| Nested replies | ❌ | ✅ | ✅ | ❌ |
| Admin moderation | ❌ | ✅ | ✅ | ✅ |
| Laravel integration | ✅ (Native) | ✅ | ❌ | ✅ |
| Cost | Free (MIT) | $$$ (Dev time) | $$$ (Subscription) | $$$ (Nova license) |
"This package lets us ship commenting features in weeks instead of months while keeping costs low. For example:
- Blogs/Forums: Add discussions to articles with real-time replies, media uploads, and spam protection—without hiring frontend devs.
- E-Commerce: Enable customers to upload photos with reviews (e.g., ‘Show your unboxing!’) using drag-and-drop, boosting engagement.
- Community Platforms: Support multiple comment systems on one page (e.g., a post and a forum thread) with multi-guard auth for shared hosting.
It’s MIT-licensed, integrates natively with Laravel, and cuts dev time by ~70% compared to building from scratch. The trade-off? We’d skip advanced features like nested replies or admin dashboards (which we can add later if needed)."
Key Metrics to Track Post-Launch:
"This is a Livewire-powered comment system that extends any Laravel model with commenting via a
use Macroabletrait. Key benefits:
- Zero JavaScript: Uses Livewire for real-time updates without React/Vue.
- Batteries Included:
- Drag-and-drop file uploads (with NSFW checks).
- Markdown/emoji support (via
highlight.js/picmo).- Multi-auth guard (e.g., ‘web’ and ‘api’ users).
- reCAPTCHA v3 for spam prevention.
- Easy Setup:
Then attach comments to any model with:composer require vigstudio/livewire-comments php artisan vendor:publish --tag=vgcomment-assets-livewire php artisan migrateuse Vigstudio\LivewireComments\Macroable; Model::macroable();Gaps to Address:
- Guest comments require manual config (see #1011).
- No nested replies or admin panel (prioritize if needed).
- CSS may conflict with Tailwind (test in staging).
Recommendation: Pilot on a low-risk feature (e.g., blog comments) before scaling. If successful, we can extend it to forums/products."*
Engineering Risks/Mitigations:
| Risk | Mitigation |
|---|---|
| CSS conflicts with Tailwind | Test in staging; use !important sparingly. |
| Performance with high comment vol | Add Redis caching for reactions/comments. |
| Missing features (e.g., mentions) | Build custom components on top. |
| Vendor lock-in | Review source code; fork if needed. |
How can I help you explore Laravel packages today?