[Vuejs]-Laravel-Vue component

0๐Ÿ‘

try this as vuejs use case sensitive

Vue.component('my-component', require('./components/MyComponent.vue').default);

and html

<body>
    <div id="app">
        <my-component></my-component>
    </div>

    <script src="{{ mix('js/app.js') }}"></script>
</body>

ref link https://v2.vuejs.org/v2/style-guide/

0๐Ÿ‘

In general, before the ending </body> tag.
Check this link for referance

<body>
  <div id="app">
    <my-component></my-component>
  </div>

   <script src="{{ asset('js/app.js') }}"></script>
</body>

Leave a comment