0

当我尝试将本地通知插件(https://github.com/katzer/cordova-plugin-local-notifications)添加到我的 Visual Studio Cordova 项目时,我收到此错误消息 -

Visual Studio 无法解析 plugin.xml。请确保 plugin.xml 存在且不包含错误。

我应该怎么做才能安装这个插件?谢谢!

4

1 回答 1

0

There appears to be a problem with the plugin.xml or VS2015. The plugin <engines is using "fuzzy" matches and it should work according to http://cordova.apache.org/docs/en/5.1.1/plugin_ref/spec.html

    <engines>
    <engine name="cordova" version=">=3.6.0" />
    <engine name="cordova" version="<4.0.0" />
</engines>

Unfortunately, the <engine name="cordova" version="<4.0.0" /> element is preventing VS2015 from loading the plugin using config.xml > Plugins > Custom

enter image description here enter image description here Temporary Fix:

  1. Download the plugin locally to the projects plugins folder
  2. Remove <engine name="cordova" version="<4.0.0" /> from cordova-plugin-local-notifications.plugin.xml
  3. Retrieve the plugin using config.xml Plugins > Custom > Local
于 2015-10-06T12:01:45.097 回答