[Vuejs]-How to optimize parameters binding from blade to Vue component's children?

0👍

You could create a javascript variable in the blade:

<script>
window.Paths = {
    img: "{{ config('base_path_images') }}"
};
</script>

And then create a computed property in the component

export default {
    computed: {
        basepathimg () {
            return window.Paths.img;
        }   
    }
}

Leave a comment