initSingleton static method
Initialize the singleton DataStore.
This should be called before using the DataStore typically in main().
e.g. await DataStore.initSingleton(DataStoreRemote());
shorebird generate will generate a server() which calls this.
Implementation
static Future<void> initSingleton(DataStore dataStore) async {
_singleton = dataStore;
await _singleton!.init();
}