Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Tag Bundle Laravel Package

berny/tag-bundle

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Simplifying Service Discovery: Accelerates development by reducing boilerplate for collecting tagged services (e.g., plugins, middleware, or event listeners) without manual CompilerPass implementation. Aligns with roadmap goals for modularity or extensibility (e.g., plugin systems, dynamic feature toggles).
  • Build vs. Buy: Justifies buying this lightweight solution over custom development for projects requiring frequent service tagging (e.g., CMS plugins, SaaS extensibility). Avoids reinventing the wheel for a niche but repetitive task.
  • Use Cases:
    • Plugin Architectures: Dynamically inject plugins (e.g., e-commerce extensions, CRM integrations) tagged with a shared namespace.
    • Middleware Pipelines: Tag and collect middleware services (e.g., auth, logging) for runtime composition.
    • Event-Driven Systems: Aggregate event subscribers or listeners by tag (e.g., event.listener.order_processed).
    • Legacy Refactoring: Replace hardcoded service dependencies with tagged injection to improve testability and decoupling.

When to Consider This Package

  • Adopt When:

    • Your Laravel/PHP project relies on tagged service discovery (e.g., plugins, dynamic modules) and currently uses custom CompilerPass implementations.
    • You prioritize developer velocity over minimalism (the package trades brevity for simplicity).
    • Your team is comfortable with MIT-licensed, archived but functional packages (low risk for short-term use).
    • You’re building a modular system where services need to be grouped by behavior (e.g., "all payment gateways") rather than hierarchy.
  • Look Elsewhere If:

    • You need active maintenance or long-term support (package is archived; consider alternatives like Symfony’s TaggedIterator or PHP-DI’s extensions).
    • Your use case requires advanced tagging logic (e.g., hierarchical tags, weighted services) beyond simple key-value pairs.
    • You’re constrained by namespace changes (package has a breaking change history; audit migration effort).
    • You prefer zero-dependency solutions (this bundle adds ~100 lines of code to your project).

How to Pitch It (Stakeholders)

For Executives: "This package cuts 30–50% of the dev time spent manually wiring tagged services (e.g., plugins, middleware) by automating the CompilerPass boilerplate. For example, if we’re building a plugin system for [Product X], we’d replace 200+ lines of custom code with a 5-line YAML tag and a single method call. It’s a low-risk, high-reward tradeoff for modularity—ideal for our [roadmap goal: extensible architecture]."

For Engineers: *"Instead of writing a CompilerPass every time you need to collect services by tag (e.g., findTaggedServices('payment.gateway')), this bundle lets you do it in 2 steps:

  1. Tag services in YAML:
    services:
        stripe_gateway:
            class: StripeGateway
            tags: { name: payment.gateway }
    
  2. Inject them dynamically:
    $gateways = $this->container->getTagged('payment.gateway');
    

It’s a drop-in replacement for repetitive CompilerPass logic, and the MIT license means no legal headaches. Tradeoff: The package is archived, but the core functionality is stable and battle-tested in Symfony ecosystems."*

For Architects: "This aligns with our principle of convention over configuration for service discovery. By standardizing on tags (e.g., feature.[name], middleware.[type]), we reduce coupling between services and the container. The bundle’s simplicity also makes it easier to mock in tests—critical for our [testability initiative]. That said, we should evaluate alternatives like Symfony’s built-in tagging if we anticipate heavy customization needs."

Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
jayeshmepani/jpl-moshier-ephemeris-php
elnasnato/laraliveui
labrodev/rest-sdk
sampaui/sampaui
babelqueue/php-sdk
facebook/capi-param-builder-php
babelqueue/symfony
hamzi/corewatch
minionfactory/raw-hydrator
hexters/coinpayment
rjcodes/rjcms
act-training/laravel-permissions-manager
alimarchal/laravel-chart-of-accounts
babenkoivan/elastic-scout-driver
mkwebdesign/filament-watchdog-v5
renatomarinho/laravel-page-speed
zedmagdy/filament-business-hours
renatovdemoura/blade-elements-ui
devgeek/beacon-admin
benjamin-rqt/data-watcher-bundle