Add caching mechanism. Adds extra option parameter dataStoreCache which defaults to false. If it is specified, it first tries to parse the parameter as JSON. If that fails, it tries to fetch the JSON as a file. Finally, if that fails, it falls back to client-side generation of dataStore. If dataStoreCache is NOT specified, it works almost exactly as before, except that most of the contents of the origin initialize function have been moved to their own function, loadMaps().