mirror of
https://code.castopod.org/adaures/castopod.git
synced 2024-09-11 12:58:04 +02:00
- configure service-worker using vite-plugin-pwa - refactor Image entity to generate images of different types based on size config - add requirement for webp library for php gd to generate webp images for instance - add action to regenerate all instance images for eventual Images config changes - enhance google lighthouse metrics for pwa
36 lines
988 B
TypeScript
36 lines
988 B
TypeScript
import { defineConfig } from "vite";
|
|
import { VitePWA } from "vite-plugin-pwa";
|
|
import { ManifestCSS } from "./vite-manifest-css";
|
|
|
|
// https://vitejs.dev/config/
|
|
export default defineConfig({
|
|
root: "./app/Resources",
|
|
base: "/assets/",
|
|
build: {
|
|
outDir: "../../public/assets",
|
|
assetsDir: "",
|
|
manifest: true,
|
|
sourcemap: true,
|
|
rollupOptions: {
|
|
input: {
|
|
"podcast.ts": "app/Resources/js/podcast.ts",
|
|
"install.ts": "app/Resources/js/install.ts",
|
|
"app.ts": "app/Resources/js/app.ts",
|
|
"admin.ts": "app/Resources/js/admin.ts",
|
|
"charts.ts": "app/Resources/js/charts.ts",
|
|
"map.ts": "app/Resources/js/map.ts",
|
|
"audio-player.ts": "app/Resources/js/audio-player.ts",
|
|
"embed.ts": "app/Resources/js/embed.ts",
|
|
"styles/index.css": "app/Resources/styles/index.css",
|
|
},
|
|
},
|
|
},
|
|
plugins: [
|
|
ManifestCSS(),
|
|
VitePWA({
|
|
manifest: false,
|
|
outDir: "../../public",
|
|
}),
|
|
],
|
|
});
|