Skip to content
This repository was archived by the owner on Jul 15, 2021. It is now read-only.
This repository was archived by the owner on Jul 15, 2021. It is now read-only.

Only load GuzzleExtension when profiler is available #261

@rvanlaak

Description

@rvanlaak

The hard dependency in composer.json on Twig can get removed, and the Twig related service definitions only have to get loaded when profiler is available and enabled.

Why?

Right now Twig is a hard requirement, although Twig does not need to be a dependency in this bundle.

  • As a result Twig will get loaded in production for API applications that don't use Twig
  • Twig solely is needed when the profiler is available and enabled in userland.

The minimum usage gets visible when searching the codebase for Twig, it all is related to the profiler.

If userland did require symfony/web-profiler-bundle, that will take care of requiring twig/twig (see related composer.json).

Proposed solution

  • remove twig dependency from composer.json
  • let CsaGuzzleExtension load service definitions when profiler class exists (instead of removing them when disabled)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions