Define a global function


#1

I am trying to use branch.io with meteor. Cordova plugin has been set up but when I try to retrieve the data from the deep linking it gives me this:

ReferenceError: Can't find variable: DeepLinkHandler

    if (data) {
      console.log('Data from deep link: ' + JSON.stringify(data));
    } else {
      console.log('No data found');
    }
  } ```

The documentation says to add that function to the code, but when I add that function. Nothing happens. Its suppose to be a global function so I tried putting it in a function with parenthesis and create a package. That didnt work either. 

If I add the function directly into the console it works.

**How can I add a global variable to meteor for cordova package to access?**

#2

My package.js was incorrectly linking to the file -.-