dimanche 26 mai 2019

Vue component is rendring but page is blank.I can see the code by inspectinng the page

i'm making static site with laravel and vue.js. I make

Route::get('/', function () {
    return view('layouts.master');
});

this route enter code hereto load home page and

import VueRouter from 'vue-router'
import home from './components/home.vue'
import About from './components/About.vue'
import Contact from './components/Contact.vue'

Vue.use(VueRouter)

const routes = [

    { path: '/about', component: About },
    {
        path: '/',
        component: home
    },
    {
        path: '/contact',
        component: Contact
    }

]

const router = new VueRouter({
    mode: 'history',
    routes, // short for `routes: routes`,

})

its my appp.js code. First time when page loaded on localhost:8000 the home page works fine but when i click to somme other route and come back it does not work it shows me blank page . but i can see html page by inspecting.



from Newest questions tagged laravel-5 - Stack Overflow http://bit.ly/2HEmiV5
via IFTTT

Aucun commentaire:

Enregistrer un commentaire