Javascript extension: Github File scope/order of execution

Silver Contributor
Silver Contributor

I've been making use of the Github integration in iQ (great feature!), and would like to know some of the details around using multiple Github Files on one extension. Here's a picture to illustrate*:


*Not 100% accurate as new files will be pushed "on top of" existing files, i.e. 3.js, 2.js, utag_ext.js instead of what's "illustrated".

1. Will all files execute?

I haven't played around with multiple drafts, but the name would suggest that there's only meant to be one final version. Do all files execute?

2. In what order do files execute?

If there's a particular order of operations that would be helpful to know -- and would cause me to lament re-ordering functionality!

3. Is each function wrapped in function(a, b) { ... } or are they all wrapped in one? Can these files reference one another?

4. Does attaching multiple files in this way go against recommended usage (should I even be considering doing this thing)?


Thanks in advance!


Javascript extension: Github File scope/order of execution

Tealium Employee

Hi @Frish 

It is possible to attach multiple files and create multiple drafts (up to 20?), however the "Approve to publish" only allows one per environemnt.

So at any given time you will not have more than one file (draft or git) per env, and therefore only the one that is published gets executed.