繁体   English   中英

如何将 Angular 中的图像 SVG 与 NativeScript 一起使用?

[英]How can I use images SVG in Angular with NativeScript?

当我想在 NativeScript 和 Angular 中使用图像 SVG 时,我遇到了问题。 我做了典型的我使用 de 标签的地方: <Image src="res://image.svg"></Image><Image src="~/images/image.svg"></Image> In NativeScript not show images in format SVG natively, the solution is use a plugin of Nativescript https://market.nativescript.org/plugins/nativescript-svg , but this plug-in does not currently work ( https://github. com/peoplewareDo/nativescript-svg/issues/24 )。 我只有 SVG 中的图像,我没有其他格式的图像。 我该怎么解决这个问题?

在检查nativescript-svg GitHub 上提供的问题后,我确实看到一些评论说bradmartin fork正在为 Android 工作。 你试过了吗?

此外,在官方 NativeScript 存储库中,有一个关于svg 支持的重新打开的问题。 因此,我建议同时将您的 svgs 文件保存为png/jpeg或任何其他受支持的格式。

干杯!

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM