I am using vue js inside laravel App. What I am trying to do here. Opening my google map in a different page. Also trying to not use layout's app.blade. So for that I start with changing #app to .app so that I can use it in different page.
const app = new Vue({
el: '.app',
});
Export my component from App.js
Vue.component('maps', require('./components/partials/map.vue').default)
And in controller
public function map(){
return view("/map");
}
Route
Route::get("/map", "MapController@map")->name("map");
Also inside the map.blade
<html>
<head>
<meta charset="utf-8">
<title></title>
</head>
<body>
<div class="app">
<maps></maps>
</div>
</body>
</html>
But in the end I can't display component. no error as well. Do I missing something here?
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire