We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Describe the bug Index.html in the dist folder. I have vue-i18n for localization and redirecting the / to /:lang/ as per the vi18n documentation
/
/:lang/
router/index.js
/* eslint-disable no-unused-vars */ import Vue from "vue"; import VueRouter from "vue-router"; const Home = () => import("../views/Home.vue"); const Services = () => import("../views/Services.vue"); const ComingSoon = () => import("../views/ComingSoon.vue"); const NotFound = () => import("../views/NotFound.vue"); import i18n from "@/i18n"; Vue.use(VueRouter); const routes = [ { path: "/", redirect: `/${i18n.locale}/`, }, // USE CODE BELOW FOR DYNAMIC ROUTES { path: "/:lang/", component: { render(c) { return c("router-view"); }, }, children: [ { path: "", name: "Home", component: { render(c) { return c(Home); }, }, }, { path: "services", name: "Services", component: { render(c) { return c(Services); }, }, }, { path: "404", name: "NotFound", component: NotFound, }, { path: "*", redirect: { name: "NotFound", }, }, ], }, ]; const router = new VueRouter({ mode: "history", routes, scrollBehavior(to, from, savedPosition) { if (to.hash) { return { selector: to.hash, // , offset: { x: 0, y: 10 } }; } }, }); export default router;
To Reproduce Steps to reproduce the behavior:
Expected behavior index.html should be in the dist folder after the app is built
Screenshots /dist/
Additional context Package version: 1.1.6 Vue version: 2.6.12 Vue CLI version: 4.5.4
The text was updated successfully, but these errors were encountered:
edit: previous image was captured during an overwrite of the dist directory
Sorry, something went wrong.
I have the same problem in vue3 :
path: "/:lang", component: { render(c) { return c("router-view"); }, },
with warnings :
No branches or pull requests
Describe the bug
Index.html in the dist folder. I have vue-i18n for localization and redirecting the
/
to/:lang/
as per the vi18n documentationrouter/index.js
To Reproduce
Steps to reproduce the behavior:
Expected behavior
index.html should be in the dist folder after the app is built
Screenshots
/dist/
Additional context
Package version: 1.1.6
Vue version: 2.6.12
Vue CLI version: 4.5.4
The text was updated successfully, but these errors were encountered: