You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For test/production purpose I need to switch application between test and production server.
I do this in my code in only one point but with the plugin I must change also preferences.
Is it possible to configure plugin (i.e. parse-server address, gcm parameters and so on) on javascript instead of config.xml?
Thanks
The text was updated successfully, but these errors were encountered:
The parameters you mentioned can't be configured solely from javascript due to the cold start cases. When notification arrives and your app is not running, the native side of Cordova gets woken up first. It's expected to handle the notification message well before the javascript side of Cordova is initialized.
That's how Cordova works, AFAIK. Because of that, if we don't have access to those parameters (via config.xml) and initialize the Parse Platform on the native side before handling Parse notifications, the app will crash.
That said, there is something you can quickly do to achieve the same "modify parameter at only 1 place" effect. Use the config.xml parameters in addition to a gulp task. This task should watch for changes in config.xml and replace a string like var MY_SERVER = "blah blah" with var MY_SERVER = "real-server-url" in the relevant javascript file.
For test/production purpose I need to switch application between test and production server.
I do this in my code in only one point but with the plugin I must change also preferences.
Is it possible to configure plugin (i.e. parse-server address, gcm parameters and so on) on javascript instead of config.xml?
Thanks
The text was updated successfully, but these errors were encountered: