Skip to content

πŸ”— A boilerplate for native applications with Tauri and Xcode using TypeScript on Vite.

Notifications You must be signed in to change notification settings

Shyam-Chen/Tauri-Starter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

26 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Tauri Starter

πŸ”— A boilerplate for native applications with Tauri and Xcode using TypeScript on Vite.

🌈 View Demo: Live | Windows | macOS | Android | iOS

:octocat: Source Code: Web-side | Native-side | Server-side | Cloud-side

Table of Contents

Getting Started

Prerequisites:

  • Node.js v20
  • PNPM v9
  • Tauri v2

Get started with Tauri Starter.

# install dependencies
$ pnpm install

# dev server (in one terminal)
# the default is to run it on macOS
$ pnpm dev:mobile
# or
$ pnpm dev:desktop

# mock server (in another terminal)
$ pnpm mock

Or use barebones scaffolding for your new Tauri app

$ pnpm dlx degit Shyam-Chen/Barebones-Templates/tauri my-tauri-app

Project Setup

Follow steps to execute this boilerplate.

Install dependencies

$ pnpm install

iOS

iOS

$ sudo xcode-select -s /Applications/Xcode.app/Contents/Developer
$ xcrun -f devicectl
$ pnpm tauri ios init
# Xcode -> Open Developer Tool -> Simulator -> File -> Open Simulator -> iPhone Pro
$ pnpm tauri ios dev
# Detected iOS simulators:
#   [1] iPhone
#   [2] iPhone Plus
#   [3] iPhone Pro
#   [4] iPhone Pro Max
#   Enter an index for a simulator above.
# Simulator: 3
$ pnpm clean:ios
$ pnpm tauri ios init
$ pnpm tauri ios build

macOS

macOS

$ pnpm tauri dev
$ pnpm tauri build

Android

Android

$ cd Library/Android/sdk/ndk/
$ ls
# 26.2.11394342

export NDK_HOME="$ANDROID_HOME/ndk/26.2.11394342"
$ pnpm tauri android init
$ pnpm tauri android dev
# select emulator
$ pnpm clean:android
$ pnpm tauri android init
$ pnpm tauri android build

Windows

$ pnpm tauri dev
$ pnpm tauri build

Mock APIs during development

$ pnpm mock

Key Features

This seed repository provides the following features:

Directory Structure

The structure follows the LIFT Guidelines.

.
β”œβ”€β”€ .github/workflows
β”‚   β”œβ”€β”€ ci.yaml
β”‚   └── publish.yaml
β”œβ”€β”€ app
β”‚   β”œβ”€β”€ public
β”‚   β”œβ”€β”€ src
β”‚   β”‚   β”œβ”€β”€ assets
β”‚   β”‚   β”œβ”€β”€ components
β”‚   β”‚   β”œβ”€β”€ composables
β”‚   β”‚   β”œβ”€β”€ layouts
β”‚   β”‚   β”œβ”€β”€ locales
β”‚   β”‚   β”œβ”€β”€ middleware
β”‚   β”‚   β”œβ”€β”€ plugins
β”‚   β”‚   β”œβ”€β”€ routes
β”‚   β”‚   β”œβ”€β”€ utilities
β”‚   β”‚   β”œβ”€β”€ workers
β”‚   β”‚   β”œβ”€β”€ App.vue
β”‚   β”‚   β”œβ”€β”€ main.ts
β”‚   β”‚   └── shims.d.ts
β”‚   β”œβ”€β”€ index.html
β”‚   β”œβ”€β”€ package.json
β”‚   β”œβ”€β”€ tsconfig.json
β”‚   └── vite.config.ts
β”œβ”€β”€ docs -> Write documentation with VitePress
β”‚   β”œβ”€β”€ .vitepress
β”‚   β”œβ”€β”€ index.md
β”‚   β”œβ”€β”€ package.json
β”‚   └── vite.config.ts
β”œβ”€β”€ e2e -> End-to-end testing
β”‚   β”œβ”€β”€ src
β”‚   β”œβ”€β”€ package.json
β”‚   β”œβ”€β”€ playwright.config.ts
β”‚   └── tsconfig.json
β”œβ”€β”€ mock -> Mock backend API
β”‚   β”œβ”€β”€ src
β”‚   β”œβ”€β”€ package.json
β”‚   β”œβ”€β”€ tsconfig.json
β”‚   └── vite.config.ts
β”œβ”€β”€ ui -> Design system
β”‚   β”œβ”€β”€ src
β”‚   β”œβ”€β”€ package.json
β”‚   β”œβ”€β”€ tsconfig.json
β”‚   └── vite.config.ts
β”œβ”€β”€ .editorconfig
β”œβ”€β”€ .eslintrc
β”œβ”€β”€ .gitignore
β”œβ”€β”€ .prettierrc
β”œβ”€β”€ package.json
β”œβ”€β”€ pnpm-lock.yaml
β”œβ”€β”€ pnpm-workspace.yaml
└── README.md

About

πŸ”— A boilerplate for native applications with Tauri and Xcode using TypeScript on Vite.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published