Developer corner
Use this section to provide examples of code or detail any information that would be deemed relevant to a developer.
For example explain how a certain feature was implemented.
API
How to use the API...
Interfaces
The following list provides information for all necessary interfaces that are used inside of this documentation. For up to date information, please check the source code.
- interface ExampleInterface
-
- Fully qualified name
-
\Er
Ha Web\ Klaro Consent Manager\ Interfaces\ Example Interface
Has to be implemented by all ...
- interface AnotherImportantInterface
-
- Fully qualified name
-
\Er
Ha Web\ Klaro Consent Manager\ Interfaces\ Another Important Interface
Used for ...
- interface RequireJsModuleInterface
-
- Fully qualified name
-
\Er
Ha Web\ Klaro Consent Manager\ Interfaces\ Require Js Module Interface
Widgets implementing this interface will add the provided RequireJS modules. Those modules will be loaded in dashboard view if the widget is added at least once.
- getRequireJsModules ( )
-
Returns a list of RequireJS modules that should be loaded, e.g.:
return [ 'ErHaWeb/KlaroConsentManager/ModuleName', 'ErHaWeb/KlaroConsentManager/Module2Name', ];
Copied!See also RequireJS (Removed) for further information regarding RequireJS in TYPO3 Backend.
- returntype
-
array
- Returns
-
List of modules to require.
Examples
A php example:
// use \TYPO3\CMS\Core\Utility\GeneralUtility;
$stuff = GeneralUtility::makeInstance(
'\\Foo\\Bar\\Utility\\Stuff'
);
$stuff->do();
Example in another language:
$(document).ready(
function () {
doStuff();
}
);
A YAML example:
services:
Vendor\Extension\EventListener\YourListener:
tags:
- name: event.listener
identifier: 'your-self-choosen-identifier'
method: 'methodToConnectToEvent'
event: ErHaWeb\KlaroConsentManager\Event\MyActionEvent