I'm sincerely sorry to behave as a noob...
Enough to do 5-6 functions in my "workinprogress" plugin in a short time of learning.
I looked through the code of the facebook plugin. Read about asynchronous option for the Google Maps API.
Nevertheless, I didn't figure out.
Let me just explain you some things.
I put this in a "googleapi.js" file
var script = document.createElement("script");
script.src = "http://maps.googleapis.com/maps/api/js?sensor=true";
window.onload = loadScript;
I "dependency" it in my edittime.js
It didn't work. I tried to put this function directly into instanceProto.onCreate = function() as well. But it didn't work too.
Each time, I can see the link correctly added in the <head> of my html test in FireBug.
But google is always not defined.
The API is correctly called only when I put the link manually into the index.html after I exported it.
Thanks for your help. I'm really grateful.
If my work helped you to make your project, please consider making a donation :)