How to write paths for assets in Laravel+vue project to component with language option?

I have pure laravel structure and my image is under:

project/resources/assets/dist/img/en/image-en.png
project/resources/assets/dist/img/fr/image-fr.png

I want to show images from my vue component in:

project/resources/assets/js/components/Templates/partials/component.vue

What are best option to handle show images in that component? My current solution is:

<template>
<img src="../../../../dist/img//image-.png">
</template>
export default {
name:'example'
data: {
lang: 'en'
}
}

How to remove ../../../../ usage from path? and reuse image path in Vue component.



from Newest questions tagged laravel-5 - Stack Overflow https://ift.tt/2zHZ1Qx
via IFTTT

تعليقات

المشاركات الشائعة من هذه المدونة

I am unable to figure out how to create payment collection request, after a form has been submitted in laravel

laravel, mysql transaction not working after failed one time