在路由配置的界面进行配置:
{
path:'*',
component: importPage('playVue/error'),
},
定义的错误页面error.vue
<template>
<div>
<h2>404</h2>
</div>
</template>
<script>
import BtUi from 'components/basic-ui/bontal-base-ui.umd.min';
export default {
name:'notFound',
data(){
return{
}
},
methods:{
}
}
</script>
<style scoped>
</style>