离子3背景图像SVG在离子视图
问题描述:
我使用的离子2.现在正在开发的应用程序不appering,我有这种风格:离子3背景图像SVG在离子视图
ion-content {
background-image: url('/assets/images/orange-background.svg');
background-repeat: no-repeat;
background-size: 101%;
}
当我ionic serve
这工作得很好,但是当我上传一个新版本到Ionic View频道,这个例子不适用于background-image
和.svg
的任何例子。
我已经试过Ionic - svg does not appear但没有工作。
在此先感谢。
编辑1
我已经尝试过的网址,background-image
:
assets/images/orange-background.svg
/assets/images/orange-background.svg
../assets/images/orange-background.svg
./assets/images/orange-background.svg
无的这个工作:“(
编辑2
我刚刚发现这个问题只发生在iOS上。
答
也许这个网址是inco rrect。在.css文件中:url ('../assets/images/orange-background.svg')
。
在其他情况下,你是否有所作为:在Whindows中,当你在浏览器中测试应用程序时,image.SVG
将起作用,但在Linux(也称为Android)中不会。看起来,image.SVG
与windows中的image.svg
相同。
感谢您的回应,但这并没有奏效。我添加了我尝试过的所有网址的编辑。 –