Project

General

Profile

Actions

Task #86196

closed

Centralize ExpressionLanguage Registration via API

Added by Susanne Moog about 6 years ago. Updated about 6 years ago.

Status:
Closed
Priority:
Should have
Assignee:
Category:
Code Cleanup
Target version:
Start date:
2018-09-07
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
9
PHP Version:
Tags:
Complexity:
Sprint Focus:

Description

Currently Symfony ExpressionLanguage is used in two contexts:

- the form framework
- typoscript condition matching

registration and providing context is done in two different ways and is extensible in two different ways. Before the LTS release these should be unified and documented.

Tasks:
- Add Configuration/ExpressionLanguage.php and corresponding loader with caching


// Config

<?php

return [
    'conditions' => [
            \TYPO3\CMS\Core\ExpressionLanguage\Typo3ConditionProvider
    ],
    'ext-form' => [
            \TYPO3\CMS\Core\ExpressionLanguage\Typo3ConditionProvider,
            \TYPO3\CMS\Form\Domain\Condition\ConditionProvider
    ]
];

// Usage:
$expressionLanguage = new \TYPO3\CMS\Core\ExpressionLanguage\Resolver('ext-form');

- Load expressionLanguage via loader with context argument in form and conditionMatcher
- Remove yaml config in form


Related issues 3 (0 open3 closed)

Related to TYPO3 Core - Feature #84133: Variants - Frontend implementationClosedRalf Zimmermann2018-05-24

Actions
Related to TYPO3 Core - Bug #92471: condition contentObject["pid"] not working in variantClosed2020-10-02

Actions
Related to TYPO3 Core - Bug #97023: EXT:form - Outdated documentation of expression languageClosedElias Häußler2022-02-24

Actions
Actions

Also available in: Atom PDF