Issue Feature Closed

#86875Feature request: Fall through for f:switch ViewHelper

Thomas Anders 11/07/18, 12:00 updated 11/07/18, 16:02

Description

A fall throug option for f:switch viewhelper would be a very nice to have.

Something like:

<f:switch expression="{expr}">

    <f:case value="val1"/>
    <f:case value="val2"/>
    <f:case value="val3">
        on one of this cases
    </f:case>

    <f:case value="val4">
        on val4
    </f:case>

    <f:defaultCase>
        default
    </f:case>

</f:switch>

Or maybe

<f:switch expression="{expr}">

    <f:case value="val1" fallthrough="val3"/>
    <f:case value="val2" fallthrough="val3"/>
    <f:case value="val3">
        on one of this cases
    </f:case>

    <f:case value="val4">
        on val4
    </f:case>

    <f:defaultCase>
        default
    </f:case>

</f:switch>

that would help in many cases where the same result should come out.

Reviews 0

No change resolves or names this issue in its commit message, and no comment links one.