Add Svelte app boilerplate (#27)

* Add Svelte app boilerplate

* Delete www folder

* Web app setup

* Fix vector images

* README
This commit is contained in:
Brahim Hadriche authored and GitHub committed 2022-12-07 12:43:33 -05:00
1 parent f71c70d90b
commit 9031f51d5d
31 files changed
+3403 -68

No files matched your search

+24
View File
@@ -0,0 +1,24 @@
import { defineConfig } from 'vite'
import { svelte } from '@sveltejs/vite-plugin-svelte'
import { readFileSync } from 'fs'
import { parse as dotEnvParse } from 'dotenv'
import { internalIpV4Sync } from 'internal-ip';
const envVars = dotEnvParse(readFileSync('../.vscode/.env'))
const PORT = 5173
// https://vitejs.dev/config/
/** @type {import('vite').UserConfig} */
export default defineConfig({
plugins: [svelte()],
build: {
outDir: "../src/www",
emptyOutDir: true
},
server: {
host: true,
port: PORT,
open: `http://${internalIpV4Sync()}:${PORT}/?host=${envVars.ROKU_DEV_TARGET}:8888`
}
})