Bug #98212
closed<f:asset.script>: identifier attribute is required
0%
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:
(1/2) #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.script src="EXT:myext/Resources/Public/Javascript/form.js"/>
Please fix that in the documentation.
Updated by Jonas Eberle about 2 years ago
- Assignee set to Jonas Eberle
Yes, the docs are not correct. I'll take care.
-- edit: It seems to be a problem with the automated Viewhelper docs generation -- https://github.com/TYPO3-Documentation/fluid-documentation-generator/issues/9
Updated by Simon Praetorius over 1 year ago
- Status changed from New to Resolved
I just checked the links you added: It's now marked as required in the documentation.