// https://nuxt.com/docs/api/configuration/nuxt-config
export default defineNuxtConfig({
	nitro: {
		preset: "node-server",
	},
	// Enable the Pages Routing Folder
	pages: true,
	modules: [
		[
			"@pinia/nuxt",
			{
				autoImports: ["defineStore", "acceptHMRUpdate"],
			},
		],
	],
	// Enable the Vuetify plugin
	css: ["vuetify/lib/styles/main.sass", "@mdi/font/css/materialdesignicons.min.css"],
	ssr: false,
	build: {
		transpile: ["vuetify"],
	},
	vite: {
		define: {
			"process.env.DEBUG": false,
		},
		server: {
			// clientPort: 443,
			https: true,
			hmr: {
				protocol: "wss",
				host: process.env.WEBUI_BASE_URL || "localhost",
			},

		},
	},
	runtimeConfig: {
		// Server side keys are available
		// Add here
		// Keys within public, will be also exposed to the client-side
		public: {
			CMS_BASE_URL: process.env.CMS_BASE_URL || "https://prescription-cms-e3btluzbiq-oa.a.run.app",
		},
	},
});
