diff --git a/mise.toml b/mise.toml index c26dfbe0..55234f44 100644 --- a/mise.toml +++ b/mise.toml @@ -8,7 +8,6 @@ experimental = true pin = true - [tasks."web:dev"] alias = ["web:up"] description = "Start frontend development server. Save file(s) to see changes" @@ -26,7 +25,7 @@ run = "pnpm install" description = "Builds the frontend for distribution/preview" env._.path = "./node_modules/.bin" dir = "{{ config_root }}" -run = "tsc && vite build" +run = "tsc -b && vite build" [tasks."web:preview"] description = "Previews frontend" @@ -34,6 +33,11 @@ env._.path = "./node_modules/.bin" dir = "{{ config_root }}" run = "vite preview" +[tasks."web:clean-preview"] +description = "Cleans out dist and then previews frontend" +env._.path = "./node_modules/.bin" +dir = "{{ config_root }}" +run = ["rm -r dist", "tsc -b && vite build", "vite preview"] [tasks."web:lint"] description = "Lints the react codebase" diff --git a/package.json b/package.json index ddf3ec24..2454e9ea 100644 --- a/package.json +++ b/package.json @@ -5,7 +5,7 @@ "type": "module", "scripts": { "dev": "vite", - "build": "tsc && vite build", + "build": "tsc -b && vite build", "preview": "vite preview" }, "dependencies": {