Skip to content

Blank or null assets:packages:*:version_strategy does not override default version_strategy #21683

Closed
@aaronm-cloudtek

Description

@aaronm-cloudtek
Q A
Bug report? yes
Feature request? no
BC Break report? no
RFC? no
Symfony version 3.2.1

With the following asset package config:

    framework:
        assets:
            version_strategy: 'app.asset.versioning.my_strategy'
            packages:
                alternate:
                    version_strategy: ~    #also tried '' here with the same result

Calls to twig helper asset('path/to/asset.css', 'alternate') are still piped through app.asset.versioning.my_strategy.

I was only able to get the desired behavior by specifying version_strategy: 'assets.empty_version_strategy' for the alternate package.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions