使用cordova-plugin-streaming-media进行视频播放但点击播放app闪退
查找后发现是插件中plugin.xml中配置没有加入到AndroidManifest.xml中,解决办法:
打开plugins文件夹下的cordova-plugin-streaming-media插件文件夹中的plugin.xml文件,并且将
<config-file target="AndroidManifest.xml" parent="/manifest">
<uses-permission android:name="android.permission.INTERNET" />
</config-file>
中的内容复制到AndroidManifest.xml中的manifest标签下,同理将
<config-file target="AndroidManifest.xml" parent="/manifest/application">
<activity android:configChanges="orientation|screenSize" android:name="com.hutchind.cordova.plugins.streamingmedia.SimpleAudioStream" android:label="Simple Audio Stream"></activity>
<activity android:configChanges="orientation|screenSize" android:name="com.hutchind.cordova.plugins.streamingmedia.SimpleVideoStream" android:label="Simple Video Stream"></activity>
</config-file>
中的内容复制到AndroidManifest.xml中的manifest标签下的application标签下
其他插件配置同理,之前是会自动生成到AndroidManifest.xml中的但是现在的插件都要手动复制一下,如果再遇到插件使app闪退的问题可以尝试以这种方式解决。