如何处理NativeScript预览应用程序中缺少的插件 [英] How to handle a missing plugin in NativeScript preview app

查看:144
本文介绍了如何处理NativeScript预览应用程序中缺少的插件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经使用NativeScript&构建了一个基本的布局应用程序; Angular,正在尝试在我的Android设备上进行预览.运行时

I've built a basic layout app with NativeScript & Angular and am trying to preview it on my android device. when running

tns预览

tns preview

我收到一条消息

插件nativescript-ng-shadow未包含在设备{{Guid}}上的预览应用中,并且无法正常工作.

Plugin nativescript-ng-shadow is not included in preview app on device {{Guid}} and will not work.

有没有办法在预览应用程序中包含此插件,或者这意味着我无法预览此应用程序?

is there a way to include this plugin on the preview app, or does that mean that that i cannot preview this app?

推荐答案

Playground支持哪些更改和应用程序有一些限制.预览应用带有内置的NativeScript插件的预定义列表(请参见下文).这意味着不支持使用带有未包含的本机代码和/或资源的插件的应用,这些应用无法在Playground的预览"应用中运行.此外,只能更改应用程序内容文件. App_Resources或插件的本机部分中的更改将不会应用.

There are some limitations of what changes and applications are supported by Playground. The Preview app comes with a predefined list of built-in NativeScript plugins (see below). This means that apps using plugins with native code and/or resources which are not included, are not supported and cannot be run in the Playground’s Preview app. Moreover only application content files can be changed. Changes in App_Resources or the native parts of the plugins will not be applied.

更多信息,请参见游乐场/预览应用程序的架构

注意: nativescript-ng-shadow插件不使用任何本机库,因此,如果将npm模块复制到项目根目录并使用相对路径导入,则仍可以使用该插件.

Note: nativescript-ng-shadow plugin doesn't use any native libraries, hence you might be still able to use the plugin if you copy the npm module to your project root and import using relative path.

这篇关于如何处理NativeScript预览应用程序中缺少的插件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆