Skip to content

Commit

Permalink
Add Tauri desktop v2 starter code
Browse files Browse the repository at this point in the history
  • Loading branch information
HuakunShen committed May 15, 2024
1 parent 825f4e5 commit 107ad55
Show file tree
Hide file tree
Showing 222 changed files with 18,911 additions and 8,482 deletions.
8 changes: 0 additions & 8 deletions Cargo.toml

This file was deleted.

26 changes: 26 additions & 0 deletions apps/desktop-v2/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# build output
dist/
# generated types
.astro/

# dependencies
node_modules/

# logs
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*


# environment variables
.env
.env.production

# macOS-specific files
.DS_Store

# jetbrains setting folder
.idea/
.vscode/
target/
47 changes: 47 additions & 0 deletions apps/desktop-v2/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
# Astro Starter Kit: Minimal

```sh
npm create astro@latest -- --template minimal
```

[![Open in StackBlitz](https://developer.stackblitz.com/img/open_in_stackblitz.svg)](https://stackblitz.com/github/withastro/astro/tree/latest/examples/minimal)
[![Open with CodeSandbox](https://assets.codesandbox.io/github/button-edit-lime.svg)](https://codesandbox.io/p/sandbox/github/withastro/astro/tree/latest/examples/minimal)
[![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/withastro/astro?devcontainer_path=.devcontainer/minimal/devcontainer.json)

> 🧑‍🚀 **Seasoned astronaut?** Delete this file. Have fun!
## 🚀 Project Structure

Inside of your Astro project, you'll see the following folders and files:

```text
/
├── public/
├── src/
│ └── pages/
│ └── index.astro
└── package.json
```

Astro looks for `.astro` or `.md` files in the `src/pages/` directory. Each page is exposed as a route based on its file name.

There's nothing special about `src/components/`, but that's where we like to put any Astro/React/Vue/Svelte/Preact components.

Any static assets, like images, can be placed in the `public/` directory.

## 🧞 Commands

All commands are run from the root of the project, from a terminal:

| Command | Action |
| :------------------------ | :----------------------------------------------- |
| `npm install` | Installs dependencies |
| `npm run dev` | Starts local dev server at `localhost:4321` |
| `npm run build` | Build your production site to `./dist/` |
| `npm run preview` | Preview your build locally, before deploying |
| `npm run astro ...` | Run CLI commands like `astro add`, `astro check` |
| `npm run astro -- --help` | Get help using the Astro CLI |

## 👀 Want to learn more?

Feel free to check [our documentation](https://docs.astro.build) or jump into our [Discord server](https://astro.build/chat).
9 changes: 9 additions & 0 deletions apps/desktop-v2/astro.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import { defineConfig } from 'astro/config';
import vue from "@astrojs/vue";

import tailwind from "@astrojs/tailwind";

// https://astro.build/config
export default defineConfig({
integrations: [vue(), tailwind()]
});
16 changes: 16 additions & 0 deletions apps/desktop-v2/components.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"$schema": "https://shadcn-vue.com/schema.json",
"style": "default",
"typescript": true,
"tailwind": {
"config": "tailwind.config.mjs",
"css": "src/styles/globals.css",
"baseColor": "zinc",
"cssVariables": true
},
"framework": "astro",
"aliases": {
"components": "@/components",
"utils": "@/lib/utils"
}
}
37 changes: 37 additions & 0 deletions apps/desktop-v2/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
{
"name": "tauri-astro-template",
"type": "module",
"version": "0.0.1",
"scripts": {
"dev": "astro dev",
"start": "astro dev",
"build": "astro check && astro build",
"preview": "astro preview",
"astro": "astro",
"tauri": "tauri"
},
"dependencies": {
"@astrojs/check": "^0.6.0",
"@astrojs/tailwind": "^5.1.0",
"@astrojs/vue": "^4.2.0",
"@internationalized/date": "^3.5.3",
"@tauri-apps/api": "2.0.0-beta.11",
"@vee-validate/zod": "^4.12.8",
"@vueuse/core": "^10.9.0",
"astro": "^4.8.2",
"class-variance-authority": "^0.7.0",
"clsx": "^2.1.1",
"lucide-vue-next": "^0.378.0",
"radix-vue": "^1.7.4",
"tailwind-merge": "^2.3.0",
"tailwindcss": "^3.4.3",
"tailwindcss-animate": "^1.0.7",
"vee-validate": "^4.12.8",
"vue": "^3.4.27",
"zod": "^3.23.8"
},
"devDependencies": {
"@tauri-apps/cli": "2.0.0-beta.17",
"typescript": "^5.4.5"
}
}
Loading

0 comments on commit 107ad55

Please sign in to comment.