I like @Twansparant’s solution. It makes sense to think of a license key as a sort of dependency of your script, and using the localize functions communicates that relationship.
Ah yes good one!
I always pass all vars in an wp or theme array, this was just as an example but indeed it should be an array, also to avoid conflicts with existing vars on the window object