나는 vuejs에서 깨어있어 어떤 이유로 다른 경로로 전환 할 때 내용을 표시하지 않습니다. 나는 다음과 같은 코드가 있습니다 : App.vue에 - 내 routes.js에서>라우터가 내용을 표시하지 않습니다. VueJS
<template>
<div>
<router-view> </router-view>
</div>
</template>
-> 내 Support.vue에서
import Support from './components/support/Support.vue';
import Detailed from './components/support/details/Detailed.vue';
export const routes =[
{path: '/support', component: Support, children: [
{path: 'detailed', component: Detailed, name: 'detailed'}
]},
];
내가 가진 컴포넌트 ->
<div class="row">
<component :is = "selectedComponent"> </component>
</div>
이고 해당 구성 요소를 선택하면 특정 콘텐츠가 표시됩니다. 이 내용의 내부 내가이 ->
<div class="most-asked">
<ul>
<router-link :to ="{name: 'detailed'}" tag = 'li'> Test </router-link>
</ul>
내가 그것을에 => "/ 지원/상세"브라우저에서 URL을 변경하지만 해당 페이지에 저를 리디렉션 나던에 눌러
. 왜 그런 일이 일어나고 어떻게 수정해야하는지에 대한 아이디어가 있습니까?PS는 내가 경로가 routes.js 별도의 할 경우 같은 -> 다음 날 완벽하게 정상적으로 리디렉션,하지만 난 지원의 자식을하면, 그것은 더 이상이
PSS에 의해 이동 나던/상세하고/지원 내 브라우저에서 가끔 저에게 말한다 어떤 이유로 자사의 같은 파일을로드 할 수 없습니다 (Failed to load resource: http://localhost:8080/support/src/vendors/css/grid.css Failed to the server responded with a status of 404 (Not Found)
그리고 난, 부트 스트랩 등 포함하면 내가 있으리라 믿고있어 http://localhost:8080/support/src/vendors/css/ionicons.min.css Failed to load resource: the server responded with a status of 404 (Not Found)
는 또한 그 경로에서 찾을하지 않을 (왜?). 그러나 모든 경로를 c없이 seperatly 넣는다면 hildren 그들은 잘 작동합니다.
경로를 '/ detailed'로 변경하면 어린이 경로가 –
전에 시도되었습니다. 브라우저 URL에서/detailed로 변경되지만/support의 동일한 페이지에 유지됩니다. – Stan