I’m new to all of this, but where I do put the callback javascript codes within WordPress? I’ve tried putting the following code using a plugin called Headers and Footers and it does not work.
CometChatWidget.launch({
// Refer to the docked or embedded layout
}).then(response => {
// OPTIONAL: This is called in the success callback of launch method
CometChatWidget.on("onMessageReceived", (args) => {
console.log("CometChatWidget onMessageReceived", args);
});
});