<template>
  <view>
    <image class="default-img" :style="{'height':!loadOver?height:0,'width':!loadOver?width:0}" :src="defaultSrc"/>
    <image class="real-img" @load="loadOverFunction" :style="{'height':loadOver?height:0,'width':loadOver?width:0}" :src="realSrc" />
  </view>
</template>

<script>
export default {
    props:['defaultSrc','realSrc','width','height'],
    data(){
        return {
            loadOver:false
        }
    },
    methods: {
        loadOverFunction(){
            this.loadOver = true
        }
    }
}
</script>

<style lang="scss" scoped>

</style>