Issue Bug Closed

#98212<f:asset.script>: identifier attribute is required

Christian Weiske 08/26/22, 12:09 updated 07/09/24, 12:46

Description

The fluid view helper “f:asset.script” documentation says the “identifier” attribute is not required:

identifier

DataType

    string
Required

    false
Description

    Use this identifier within templates to only inject your JS once, even though it is added multiple times.

- https://docs.typo3.org/other/typo3/view-helper-reference/main/en-us/typo3/fluid/latest/Asset/Script.html
- https://docs.typo3.org/other/typo3/view-helper-reference/10.4/en-us/typo3/fluid/latest/Asset/Script.html

Yet when omitting the attribute I get an exception in TYPO3 10.4.28:

> ½ #1237823699 TYPO3Fluid\Fluid\Core\Parser\Exception
>
> Fluid parse error in template Form_action_data_c6ac93081190f90754d41ae7e65a05164b226925, line 13 at character 4. Error: Required argument “identifier” was not supplied. (error code 1237823699). Template source chunk: <f:asset src="EXT:myext/Resources/Public/Javascript/form.js"></f:asset>

Please fix that in the documentation.

Reviews 0

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