خرید بک لینک

Vote count: 0

I have written a custom Cordova plugin that brings as a dependency "Media" plugin.

When i run "cordova plugin add "myPlugin"" the plugin is installed to the sample project however when in my index.js i try to init my plugin it does not recognise it and if i try to create "Media" object it does.

Here is my plugin .xml file :

<?xml version="1.0" encoding="utf-8"?>
<plugin xmlns="http://www.phonegap.com/ns/plugins/1.0"
        id="cordova-plugin-MyPlugin"
        version="1.0.0">

  <name> MyPlugin </name>
  <description>Cordova MyPlugin Plugin</description>
  <author> MyPlugin </author>
    <license>MIT</license>
    <keywords> MyPlugin </keywords>

    <dependency id="org.apache.cordova.media"/>


  <js-module src="www/MyPlugin.js" name="MyPlugin">
    <clobbers target="window.plugins.MyPlugin" />
  </js-module>



  <platform name="ios">
    <config-file target="config.xml" parent="/*">
      <feature name="MyPlugin">
        <param name="ios-package" value="CDVMyPlugin" />
      </feature>
    </config-file>

    <!-- Sources -->
    <header-file src="src/ios/CDVMyPlugin.h"/>
    <source-file src="src/ios/CDVMyPlugin.m"/>


    <!-- iOS Frameworks -->
    <framework src="libz.dylib" />

  </platform>

</plugin>

Thanks for the help.

asked 2 mins ago

برچسب: نویسنده: استخدام کار تاريخ: دوشنبه 16 فروردين 1395 ساعت: 22:15

صفحه بندی