Fix reload button

This commit is contained in:
NBTX
2019-08-24 18:16:52 +01:00
parent b678d848db
commit 8d35e7d3bd

View File

@@ -4,7 +4,7 @@
<h2>{{ error.message }}</h2> <h2>{{ error.message }}</h2>
<br> <br>
<p><nuxt-link to="/"><button>Go Home</button></nuxt-link></p> <p><nuxt-link to="/"><button>Go Home</button></nuxt-link></p>
<p><a :href="base">Reload</a></p> <p><a href="" @click.prevent="reloadApplication">Reload</a></p>
</div> </div>
</template> </template>
@@ -22,14 +22,12 @@
</style> </style>
<script> <script>
import { routerBase } from '../nuxt.config';
export default { export default {
props: ['error'], props: ['error'],
data () { methods: {
return { reloadApplication () {
base: routerBase.router.base this.$router.push('/', () => window.location.reload());
} }
}, },