Github user TimBarham commented on a diff in the pull request:

    https://github.com/apache/cordova-lib/pull/247#discussion_r35482469
  
    --- Diff: 
cordova-lib/spec-plugman/plugins/org.test.defaultvariables/plugin.xml ---
    @@ -0,0 +1,16 @@
    +<?xml version="1.0" encoding="UTF-8"?>
    +
    +<plugin xmlns="http://cordova.apache.org/ns/plugins/1.0";
    +    xmlns:android="http://schemas.android.com/apk/res/android";
    +    id="org.test.defaultvariables"
    +    version="3.0.0">
    +
    +    <name>Use Default Variables</name>
    +
    +    <!-- android -->
    +    <platform name="android">
    +            <preference name="ENABLE_LOG" default="yes" />
    +            <preference name="API_KEY" />
    +    </platform>
    --- End diff --
    
    If you are creating a plugin, and need to use variables because some values 
will need to be defined by the app developer, you *use* the variable by 
including a reference to it in values in your plugin's `plugin.xml`. The value 
of the variable (whether the default value specified in the `preference` 
element, or a value supplied by the app developer when the plugin is added to 
their project) is substituted for references to the variable in values in 
`plugin.xml` when those values are used. See 
[here](https://cordova.apache.org/docs/en/5.1.1/plugin_ref_spec.md.html#variables)
 for some more info.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@cordova.apache.org
For additional commands, e-mail: dev-h...@cordova.apache.org

Reply via email to