알쓸전컴(알아두면 쓸모있는 전자 컴퓨터)
해당 방법은 1번 보다 vue 공식 문서에 좀 더 가까운 방법 입니다. 저의 publicPath 은 아래와 같습니다. 톰캣과 맞췄습니다. 아래는 현재 router 셋팅 입니다., import Vue from 'vue' import VueRouter, { RouteConfig } from 'vue-router' import Home from '../views/Home.vue' import TestHistoryPage from "@/views/TestHistoryPage.vue" Vue.use(VueRouter) const routes: Array = [ { path: '/', name: 'Home', component: Home }, { path: '/about', name: 'About', // rout..
vue histroy 모드를 tomcat 에서 그냥 사용 하면 url로 어떤 경로를 바로 접속시 404 에러를 만납니다. const router = new VueRouter({ mode: 'history', routes }) vue.config.js module.exports = { publicPath: "/authComponent/", } 아래와 같이 라우팅이 잡혀 있을때. const routes: Array = [ { path: '/authComponent', name: 'Home', component: Home }, { path: '/authComponent/about', name: 'About', // route level code-splitting // this generates a separa..