Skip to content

Instantly share code, notes, and snippets.

@davecra
Last active May 29, 2020 19:59
Embed
What would you like to do?
Required code for web pack to work in a project
/*************************************************/
/* REQUIRED BY WEB PACK - DO NOT DELETE */
/*************************************************/
function getGlobal() {
return typeof self !== "undefined"
? self
: typeof window !== "undefined"
? window
: typeof global !== "undefined"
? global
: undefined;
}
const g = getGlobal();
g.onSendEvent = onSendEvent;
g.onRibbonButtonClick = onRibbonButtonClick
/*************************************************/
/* REQUIRED BY WEB PACK - DO NOT DELETE */
/*************************************************/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment