}
```
+`__DIR__` is the folder path of your addon.
+
## JavaScript
### Global scripts
}
```
+`__DIR__` is the folder path of your addon.
+
### JavaScript hooks
The main Friendica script provides hooks via events dispatched on the `document` property.
```
- *name* is the name of the hook and corresponds to a known Friendica JavaScript hook.
-- *callback* is a JavaScript function to execute.
+- *callback* is a JavaScript anonymous function to execute.
+
+More info about Javascript event listeners: https://developer.mozilla.org/en-US/docs/Web/API/EventTarget/addEventListener
#### Current JavaScript hooks
### src/App.php
Addon::callHooks('load_config');
- Addon::callHooks('head');
+ Addon::callHooks('head');
Addon::callHooks('footer');
### src/Model/Item.php