-
Notifications
You must be signed in to change notification settings - Fork 94
Open
Labels
Description
The standard UMD header does not work within Shared Workers. Shared Workers run in a browser, however, these do not have access to window.
if (typeof exports !== "undefined" && exports !== null) {
exports.Stomp = Stomp;
}
if (typeof window !== "undefined" && window !== null) {
window.Stomp = Stomp;
} else if (!exports) {
self.Stomp = Stomp;
}The above block would give undefined exports.
To fix this problem, please define the following before including stompjs.
self.exports = {};synscen