Sample.app
Framework Guides

Vue

Deploy a Vue (Vite) project to Sample.app.

Vue apps created with create-vue or Vite output to dist/ by default, which the CLI auto-detects.

Deploy

Build your project

npm run build

Deploy to Sample.app

samplex deploy

Or specify explicitly:

samplex deploy ./dist

Vue Router (history mode)

If you're using Vue Router in history mode, Sample.app's SPA fallback handles it automatically — all unmatched routes serve /index.html.

No server-side configuration or 404.html workaround needed. SPA fallback is built in.

Custom output directory

If you've changed the output directory:

vite.config.ts
export default defineConfig({
  build: {
    outDir: "my-output",
  },
});
samplex deploy ./my-output

On this page