Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changes/changes.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"create-tauri-app": minor
---

Vite with SWC in React templates.
2 changes: 1 addition & 1 deletion templates/template-react-ts/package.json.lte
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"devDependencies": {
"@types/react": "^18.2.15",
"@types/react-dom": "^18.2.7",
"@vitejs/plugin-react": "^4.2.1",
"@vitejs/plugin-react-swc": "^3.5.0",
"typescript": "^5.0.2",
"vite": "^5.0.0",
"@tauri-apps/cli": "^{% if alpha %}2.0.0-alpha.20{% else %}1.5.8{% endif %}"{% if mobile %},
Expand Down
2 changes: 1 addition & 1 deletion templates/template-react-ts/vite.config.ts.lte
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { defineConfig } from "vite";
import react from "@vitejs/plugin-react";{% if mobile %}
import react from "@vitejs/plugin-react-swc";{% if mobile %}
import { internalIpV4 } from "internal-ip";

// @ts-expect-error process is a nodejs global
Expand Down
2 changes: 1 addition & 1 deletion templates/template-react/package.json.lte
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
"@tauri-apps/plugin-shell": "^2.0.0-alpha.3"{% endif %}
},
"devDependencies": {
"@vitejs/plugin-react": "^4.2.1",
"@vitejs/plugin-react-swc": "^3.5.0",
"vite": "^5.0.0",
"@tauri-apps/cli": "^{% if alpha %}2.0.0-alpha.20{% else %}1.5.8{% endif %}"{% if mobile %},
"internal-ip": "^7.0.0"{% endif %}
Expand Down
2 changes: 1 addition & 1 deletion templates/template-react/vite.config.js.lte
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { defineConfig } from "vite";
import react from "@vitejs/plugin-react";{% if mobile %}
import react from "@vitejs/plugin-react-swc";{% if mobile %}
import { internalIpV4 } from "internal-ip";

const mobile = !!/android|ios/.exec(process.env.TAURI_ENV_PLATFORM);{% endif %}
Expand Down