Closed
Description
Version
1.3.1
Reproduction link
https://play.nativescript.org/?template=play-vue&id=3SaUXi
Platform and OS info
Android
Steps to reproduce
- Create an app with vue cli the in your HelloWrold Template
<template>
<Page class="page">
<ActionBar class="action-bar" title="Poket Gif" />
<StackLayout class="layout">
<SearchBar hint="Chercher un gif" ref="search" v-model="q" @submit="search" />
<ListView for="img in imgs" height="100%">
<v-template>
<ImageCard :src="img.images.downsized.url" />
<!-- <Image :src="img.images.downsized.url" stretch="aspectFit" /> -->
</v-template>
</ListView>
</StackLayout>
</Page>
</template>
- Create the ImageCard component
<script>
export default {
props: {
src: {
type: String,
required: true
}
}
}
</script>
<template>
<Image :src="src" stretch="aspectFit" />
</template>
What is expected?
Some images to be shown
What is actually happening?
Refreshing application...
Successfully synced application io.pokegif.mobile on device emulator-5554.
ActivityManager: Start proc 30709:io.pokegif.mobile/u0a86 for activity io.pokegif.mobile/com.tns.NativeScriptActivity JS: 'NativeScript-Vue has "Vue.config.silent" set to true, to see output logs set it to false.'
05-20 15:20:50.618 30709 30709 E AndroidRuntime: at com.tns.Runtime.callJSMethodNative(Native Method)
05-20 15:20:50.618 30709 30709 E AndroidRuntime: at com.tns.Runtime.dispatchCallJSMethodNative(Runtime.java:1088)
05-20 15:20:50.618 30709 30709 E AndroidRuntime: at com.tns.Runtime.callJSMethodImpl(Runtime.java:970)
05-20 15:20:50.619 30709 30709 E AndroidRuntime: at com.tns.Runtime.callJSMethod(Runtime.java:957)
05-20 15:20:50.619 30709 30709 E AndroidRuntime: at com.tns.Runtime.callJSMethod(Runtime.java:941)
05-20 15:20:50.619 30709 30709 E AndroidRuntime: at com.tns.Runtime.callJSMethod(Runtime.java:933)
System.err: com.tns.NativeScriptException:
System.err: Calling js method getView failed
System.err:
System.err: Error: Cannot convert object to Landroid/graphics/Bitmap; at index 0
System.err: File: "file:///data/data/io.pokegif.mobile/files/app/tns_modules/tns-core-modules/ui/image/image.js, line: 143, column: 23
System.err:
System.err: StackTrace:
System.err: Frame: function:'Image.(anonymous function)', file:'file:///data/data/io.pokegif.mobile/files/app/tns_modules/tns-core-modules/ui/image/image.js', line: 143, column: 24
System.err: Frame: function:'Property.set', file:'file:///data/data/io.pokegif.mobile/files/app/tns_modules/tns-core-modules/ui/core/properties/properties.js', line: 116, column: 44
System.err: Frame: function:'ImageBase._createImageSourceFromSrc', file:'file:///data/data/io.pokegif.mobile/files/app/tns_modules/tns-core-modules/ui/image/image-common.js', line: 107, column: 30
System.err: Frame: function:'Image._createImageSourceFromSrc', file:'file:///data/data/io.pokegif.mobile/files/app/tns_modules/tns-core-modules/ui/image/image.js', line: 101, column: 56
System.err: Frame: function:'Image.(anonymous function)', file:'file:///data/data/io.pokegif.mobile/files/app/tns_modules/tns-core-modules/ui/image/image.js', line: 154, column: 14
System.err: Frame: function:'applyAllNativeSetters', file:'file:///data/data/io.pokegif.mobile/files/app/tns_modules/tns-core-modules/ui/core/properties/properties.js', line: 961, column: 28
System.err: Frame: function:'initNativeView', file:'file:///data/data/io.pokegif.mobile/files/app/tns_modules/tns-core-modules/ui/core/properties/properties.js', line: 905, column: 9
System.err: Frame: function:'ViewBase.onResumeNativeUpdates', file:'file:///data/data/io.pokegif.mobile/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 555, column: 22
System.err: Frame: function:'ViewBase._resumeNativeUpdates', file:'file:///data/data/io.pokegif.mobile/files/app/tns_modules/tns-core-modules/ui/core/view-base/view-base.js', line: 223, column: 18
When I put a Label in the ImageCard component instead of an Image, it works (and shows as text the src url), but as soon as it is an Image, it doesn't work, while when the Image is placed directly in the loop, without a crapper component, it works
Metadata
Metadata
Assignees
Labels
No labels