Skip to content

Commit

Permalink
Update: Vite config
Browse files Browse the repository at this point in the history
  • Loading branch information
antidoid committed Jan 30, 2024
1 parent b6c340b commit bf27b45
Showing 1 changed file with 14 additions and 6 deletions.
20 changes: 14 additions & 6 deletions frontend/vite.config.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,15 @@
import { defineConfig } from 'vite'
import react from '@vitejs/plugin-react'
import { defineConfig } from "vite";
import react from "@vitejs/plugin-react";

// https://vitejs.dev/config/
export default defineConfig({
plugins: [react()],
})
export default defineConfig(({ command }) => {
const config = {
plugins: [react()],
base: "/",
};

if (command !== "serve") {
config.base = "/az-qr-code/";
}

return config;
});

0 comments on commit bf27b45

Please sign in to comment.