generated from oSethoum/tauri-react-template
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 583c00a
Showing
37 changed files
with
4,899 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# Logs | ||
logs | ||
*.log | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* | ||
pnpm-debug.log* | ||
lerna-debug.log* | ||
|
||
node_modules | ||
dist | ||
dist-ssr | ||
*.local | ||
|
||
# Editor directories and files | ||
.vscode/* | ||
!.vscode/extensions.json | ||
.idea | ||
.DS_Store | ||
*.suo | ||
*.ntvs* | ||
*.njsproj | ||
*.sln | ||
*.sw? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
# React-tauri-vite-template | ||
|
||
Simple template to get started with react vite and tauri, note that it has typescript support also, ~~It enables the vite-plugin-tauri, to avoid ghost terminal issue~~. | ||
|
||
## why ? | ||
|
||
Because it's fun. | ||
|
||
## Requirements: | ||
|
||
[here](https://tauri.app/v1/guides/getting-started/prerequisites) | ||
|
||
## Instructions | ||
|
||
1- install dependencies | ||
|
||
```sh | ||
#npm | ||
npm install | ||
|
||
#yarn | ||
yarn | ||
``` | ||
|
||
2- Run the App in development mode: | ||
|
||
```sh | ||
#npm | ||
npm run tauri:dev | ||
|
||
#yarn | ||
yarn tauri:dev | ||
``` | ||
|
||
note that the first run will take time as tauri download and compile dependencies. | ||
|
||
## Production | ||
|
||
when you are happy with the results and ready to ship your useless app. | ||
|
||
run: | ||
|
||
```sh | ||
#npm | ||
npm run tauri:build | ||
|
||
#yarn | ||
yarn tauri:build | ||
``` | ||
|
||
## Note: | ||
|
||
tested on: | ||
|
||
- windows 10 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<!DOCTYPE html> | ||
<html lang="en"> | ||
<head> | ||
<meta charset="UTF-8" /> | ||
<link rel="icon" type="image/svg+xml" href="/src/favicon.svg" /> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> | ||
<title>Vite App</title> | ||
</head> | ||
<body> | ||
<div id="root"></div> | ||
<script type="module" src="/src/main.tsx"></script> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
{ | ||
"name": "tauri-react-template", | ||
"private": true, | ||
"version": "0.1.0", | ||
"scripts": { | ||
"dev": "vite", | ||
"build": "tsc && vite build", | ||
"preview": "vite preview", | ||
"tauri:dev": "tauri dev", | ||
"tauri:build": "tauri build" | ||
}, | ||
"dependencies": { | ||
"@tauri-apps/api": "^1.0.1", | ||
"react": "^18.0.0", | ||
"react-dom": "^18.0.0" | ||
}, | ||
"devDependencies": { | ||
"@tauri-apps/cli": "^1.0.2", | ||
"@types/react": "^18.0.0", | ||
"@types/react-dom": "^18.0.0", | ||
"@vitejs/plugin-react": "^1.3.0", | ||
"typescript": "^4.6.3", | ||
"vite": "^2.9.9" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# Generated by Cargo | ||
# will have compiled files and executables | ||
/target/ |
Oops, something went wrong.