The width and height of the image requested by vue for multiple pages is 0 * 0.

the project I developed is a multi-page application, and the second html page created cannot be developed in the form of vue single-file components, so the DOM structure is written in the html page, but the relative path is used in html to introduce the picture, and it is found that the picture returns 0 * 0. What"s going on? solve

Mar.18,2021

<template>
    <img :src="img_code">
</template>
<script>
  import img_code from '@/assets/images/code.jpg'
export default {
    data(){
        return{
          img_code
        }
       }
    }
</script>


I've seen this problem five times in sf. https://github.com/vuejs/vue-.

Menu