- Issue created by @jansete
- Status changed to Needs review
almost 2 years ago 1:07pm 9 June 2023 - last update
almost 2 years ago 8 fail The last submitted patch, 2: feature-toggle_add_twig_compability-3365885-2.patch, failed testing. View results →
- codesniffer_fixes.patch Interdiff of automated coding standards fixes only.- last update
almost 2 years ago 5 pass - 🇪🇸Spain jansete
Replace trait to abstract service base to allow override constructor.
- 🇪🇸Spain plopesc Valladolid
This looks like a nice feature and I would be probably interested in having it.
However, I think would be better to implement it as a twig function to avoid using hook_preprocess(), which could be overkill. - Merge request !16Issue #3365885: Allow access enabled toggles in twig templates → (Merged) created by plopesc
- 🇪🇸Spain plopesc Valladolid
Created MR adding a new Twig function feature_toggle_status that gets a feature name as parameter. It would return TRUE if the feature exists and is enabled. FALSE otherwise.
{%- if feature_toggle_status('my_feature') -%}passed{%- else -%}rejected{%- endif -%}
Automatically closed - issue fixed for 2 weeks with no activity.