me.apla.cordova.app-preferences
me.apla.cordova.app-preferences copied to clipboard
Are there any examples?
The documentation is a little thin. I don't really even know where to get started. Are there any examples?
You can check the README.md file, very clear :)
Hmm - I did look at README.md. It has good documentation on the API, but I really don't quite understand how to get from "here is a list of things I want in a preference panel set" to "my application shows its preferences panels when the user clicks here". That's what I meant by an example.
This plugin contains 2 parts:
- Javascript interface to access preferences;
- Native preferences interface generator.
Seems like you need to use preference generator. And preference generator docs is thin. Here is some notes on how to achieve what do you want:
- Install latest version of plugin. After plugin is installed, you can inspect
app-settings.json
in app folder (or here). - There is supported fields list: https://github.com/apla/me.apla.cordova.app-preferences#preferences-interface-generator
- Please run
cordova prepare
afterapp-settings.json
modification - In your app call
appPreferences.show()
to display preferences. Please note, on android preferences don't reflect default values (#62).
Hi,I'm quite new to this too.For what I know, MDM can set some app configuration values for application. For example, I need email address to be retrieved from MDM. (http://www.appconfigforenterprise.org/dev-center/)How can I get the value by this plugin? I'm quite lost about all this. Like: What does the app-settings.json do? Does it populate plist/xml file for application? Would that be enough if I just add the EmailAddress key in the app-settings.json?
BTW, how can I test the scenario like above?
Your help would be really appreciated! This would be much helpful if you could provide the newbies with some sample application(ionic or other frameworks) !!
Thanks anyway.