I load my config file the standard way:
<script src="https://apps.mypurecloud.com/widgets/9.0/cxbus.min.js"
onload="javascript:CXBus.configure({debug:false,pluginsPath:'https://apps.mypurecloud.com/widgets/9.0/plugins/'});
CXBus.loadFile('<%=request.getContextPath()%>/resources/js/GenesysCloudChat/GenesysChatConfig.js').done(function(){CXBus.loadPlugin('widgets-core')});">
</script>
My GenesysChatConfig.js file looks like so:
window._genesys = {
widgets : {
main : {
theme : 'light',
preload: ['webchat'],
},
webchat : {
actionsMenu : true,
uploadsEnabled : true,
confirmFormCloseEnabled : true,
charCountEnabled : true,
chatButton: {
enabled: false
},
transport : {
type : 'purecloud-v2-sockets',
dataURL : 'https://api.mypurecloud.com',
deploymentKey : [KEY_HERE],
orgGuid : [ORG_GUID_HERE],
interactionData : {
routing : {
targetType : 'QUEUE',
targetAddress : [CHAT_QUEUE_NAME_HERE],
priority : 2
}
}
},
},
}
};
However, if I add the following code to my GenesysChatConfig.js (or call this code outside of this .js file, even):
const chatPlugin = CXBus.registerPlugin('Custom');
chatPlugin.subscribe('WebChatService.ready', function (e) {
console.log('Chat ready', e);
});
then the jQuery that runs my ui-datepicker-trigger from the jQuery library (jquery-ui-1.8.6.custom.min.js) stops functioning completely. No errors are thrown when I try to click on the datepicker, it's just completely unresponsive. I see this behavior consistently and if I remove the "subscribe" code, it works okay (creating the "chatPlugin" is fine). This happens on any and every subscribe event (WebChatService, Overlay, Toaster, WindowManager, etc.).
Any help would be greatly appreciated, thank you!
Colton