- 🇬🇧United Kingdom malcomio
See also #2842386: [Regression] Restore Javascript APi → and ✨ Allow AjaxResponse to be altered RTBC
- Status changed to Closed: duplicate
about 2 months ago 6:57am 12 March 2025
I want ot hook into the flag ajax command, do something in js after flag sucess. it is possile in Drupal 7:
https://www.drupal.org/node/336122 →
"
The Flag module provides us with two "pseudo" events to which we can attach our JavaScript handlers. These events are both triggered after content has been successfully flagged (or unflagged).
"
$(document).bind('flagGlobalAfterLinkUpdate', function(event, data) {
alert('Object #' + data.contentId + ' (of type ' +
data.contentType + ') has been ' + data.flagStatus +
' using flag "' + data.flagName + '"');
});
Is this possible in Drupal 8?
Active
4.0
User interface
Not all content is available!
It's likely this issue predates Contrib.social: some issue and comment data are missing.
See also #2842386: [Regression] Restore Javascript APi → and ✨ Allow AjaxResponse to be altered RTBC