When my project integrates vue-router-sync, the URL hash value is automatically deleted every time the page is relaoded
NUXT : RC-6
module.exports = {
/*
** Headers of the page
*/
head: {
title: 'starter',
meta: [
{ charset: 'utf-8' },
{ name: 'viewport', content: 'width=device-width, initial-scale=1' },
{ hid: 'description', name: 'description', content: 'Nuxt.js project' }
],
link: [
{ rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' }
]
},
/*
** Global CSS
*/
css: ['~assets/css/main.css'],
/*
** Customize the progress-bar color
*/
loading: { color: '#3B8070' },
plugins: [{
src: '~/plugins/router.js'
}]
}
// plugins/router.js
import { sync } from 'vuex-router-sync'
export default function ({ app: {store, router, $axios }, error, isServer }) {
sync(store, router)
}
<!--cmty--><!--cmty_prevent_hook--><div align="right"><sub><em>This question is available on <a href="https://nuxtjs.cmty.io">Nuxt.js</a> community (<a href="https://nuxtjs.cmty.io/nuxt/nuxt.js/issues/c1361">#c1361</a>)</em></sub></div>