2024-05-20 14:43:25 +00:00
< div align = "center" >
2023-12-30 07:49:49 +00:00
2024-05-21 04:02:27 +00:00
< img src = "https://cdn.jsdelivr.net/gh/easy-temps/easy-static/cover.png" alt = "cover" / >
2024-05-22 09:33:16 +00:00
< h1 align = "center" > vue3-vant-mobile< / h1 >
2024-05-21 04:02:27 +00:00
2024-05-20 14:43:25 +00:00
English / [简体中文 ](./README.zh-CN.md )
2022-06-22 04:55:17 +00:00
2024-05-20 14:43:25 +00:00
An mobile web apps template based on the Vue 3 ecosystem.
2022-06-22 04:55:17 +00:00
2024-05-20 14:43:25 +00:00
一个基于 Vue 3 生态系统的移动 web 应用模板,帮助你快速完成业务开发。
2023-04-17 13:38:58 +00:00
2024-05-20 14:43:25 +00:00
< p >
< img src = "https://img.shields.io/github/license/easy-temps/vue3-vant-mobile" alt = "license" / >
< img src = "https://img.shields.io/github/package-json/v/easy-temps/vue3-vant-mobile" alt = "version" / >
< img src = "https://img.shields.io/github/repo-size/easy-temps/vue3-vant-mobile" alt = "repo-size" / >
< img src = "https://img.shields.io/github/languages/top/easy-temps/vue3-vant-mobile" alt = "languages" / >
< img src = "https://img.shields.io/github/issues-closed/easy-temps/vue3-vant-mobile" alt = "issues" / >
2023-12-30 07:49:49 +00:00
< / p >
2022-06-22 04:55:17 +00:00
2024-05-20 14:43:25 +00:00
[文档 ](https://easy-temps.github.io/easy-docs/vue3-vant-mobile/ ) / [交流 ](https://github.com/easy-temps/vue3-vant-mobile/issues/56 ) / [反馈 ](https://github.com/easy-temps/vue3-vant-mobile/issues )
2024-12-09 12:43:53 +00:00
< a href = "https://vue3-vant-mobile.netlify.app" > 🖥 Live Demo< / a >
2024-05-20 14:43:25 +00:00
[](https://app.netlify.com/sites/vue3-vant-mobile/deploys)
< / div >
2023-12-30 07:49:49 +00:00
< br >
2022-06-22 04:55:17 +00:00
2023-12-30 07:49:49 +00:00
## Features
2022-07-12 02:57:36 +00:00
2024-12-17 02:36:28 +00:00
- ⚡️ [Vue 3 ](https://github.com/vuejs/core ), [Vite 6 ](https://github.com/vitejs/vite ), [pnpm ](https://pnpm.io/ ), [esbuild ](https://github.com/evanw/esbuild ) - born with fastness
2022-06-22 04:55:17 +00:00
2024-01-09 09:38:13 +00:00
- 🗂 [File based routing ](./src/router )
2023-12-30 07:49:49 +00:00
- 📦 [Components auto importing ](./src/components )
- 🍍 [State Management via Pinia ](https://pinia.vuejs.org )
2024-03-08 04:01:56 +00:00
- 📲 [PWA ](https://github.com/antfu/vite-plugin-pwa )
2023-12-30 07:49:49 +00:00
- 🎨 [UnoCSS ](https://github.com/antfu/unocss ) - the instant on-demand atomic CSS engine
2024-03-29 11:20:31 +00:00
- 🌍 [I18n ready ](./src/locales )
2023-12-30 07:49:49 +00:00
- 🔥 Use the [new `<script setup>` syntax ](https://github.com/vuejs/rfcs/pull/227 )
- 📥 [APIs auto importing ](https://github.com/antfu/unplugin-auto-import ) - use Composition API and others directly
- 💪 TypeScript, of course
- ⚙️ Unit Testing with [Vitest ](https://github.com/vitest-dev/vitest )
- 💾 [Mock ](https://github.com/pengzhanbo/vite-plugin-mock-dev-server ) server Support
- 🌈 Git [hooks ](./.husky ) - lint and commit
- 🪶 [Vant ](https://github.com/youzan/vant ) - Vue UI library for mobile web apps
- 🔭 [vConsole ](https://github.com/vadxq/vite-plugin-vconsole ) - the developer tool for mobile web page
- 📱 Browser adaptation - use viewport vw/vh units
- 💻 [Desktop optimization ](https://github.com/wswmsword/postcss-mobile-forever ) - the mobile area
- 🌓 Dark Mode Support
- 🛡️ Configure [ESM ](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Modules ) as default
2022-10-25 04:03:06 +00:00
2023-12-30 07:49:49 +00:00
- ☁️ Deploy on [Netlify ](https://www.netlify.com ), zero-config
2022-06-22 04:55:17 +00:00
2023-12-30 07:49:49 +00:00
< br >
2022-06-22 04:55:17 +00:00
2023-12-30 07:49:49 +00:00
## Pre-packed
### UI Frameworks
2024-01-03 01:47:42 +00:00
- [UnoCSS ](https://github.com/antfu/unocss ) - The instant on-demand atomic CSS engine
- [`@unocss/preset-rem-to-px` ](https://github.com/unocss/unocss/tree/main/packages/preset-rem-to-px ) - Converts rem to px for all utilities
- [`eslint-plugin-unocss` ](https://github.com/devunt/eslint-plugin-unocss ) - ESLint plugin for UnoCSS
- [Vant ](https://github.com/youzan/vant ) - Vue UI library for mobile web apps
- [`vant-touch-emulator` ](https://github.com/youzan/vant/tree/main/packages/vant-touch-emulator ) - Simulate mobile touch events on the desktop
- [`vant-use` ](https://github.com/youzan/vant/tree/main/packages/vant-use ) - Built-in composition APIs of Vant
2023-12-30 07:49:49 +00:00
### Plugins
- [Vue Router ](https://github.com/vuejs/router )
2024-01-09 09:38:13 +00:00
- [`unplugin-vue-router` ](https://github.com/posva/unplugin-vue-router ) - file system based routing
2024-01-03 01:47:42 +00:00
- [Pinia ](https://pinia.vuejs.org ) - Intuitive, type safe, light and flexible Store for Vue using the composition api
- [`pinia-plugin-persistedstate` ](https://github.com/prazdevs/pinia-plugin-persistedstate ) - Configurable persistence and rehydration of Pinia stores
2024-03-29 11:20:31 +00:00
- [Vue I18n ](https://github.com/intlify/vue-i18n-next ) - Internationalization
- [`unplugin-vue-i18n` ](https://github.com/intlify/bundle-tools/tree/main/packages/unplugin-vue-i18n ) - unplugin for Vue I18n
2023-12-30 07:49:49 +00:00
- [unplugin-vue-components ](https://github.com/antfu/unplugin-vue-components ) - components auto import
- [unplugin-auto-import ](https://github.com/antfu/unplugin-auto-import ) - Directly use Vue Composition API and others without importing
2024-01-03 01:47:42 +00:00
- [vite-plugin-vconsole ](https://github.com/vadxq/vite-plugin-vconsole ) - A lightweight, extendable front-end developer tool for mobile web page
- [vite-plugin-mock-dev-server ](https://github.com/pengzhanbo/vite-plugin-mock-dev-server ) - Vite Plugin for API mock dev server
- [postcss-mobile-forever ](https://github.com/wswmsword/postcss-mobile-forever ) - To adapt different displays by one mobile viewport
2024-02-26 17:03:41 +00:00
- [vite-plugin-vue-devtools ](https://github.com/vuejs/devtools-next ) - Designed to enhance the Vue developer experience
- [vueuse ](https://github.com/antfu/vueuse ) - collection of useful composition APIs
- [@unhead/vue ](https://github.com/unjs/unhead ) - manipulate document head reactively
2024-03-08 04:01:56 +00:00
- [vite-plugin-pwa ](https://github.com/antfu/vite-plugin-pwa ) - PWA
2024-03-08 08:10:27 +00:00
- [vite-plugin-sitemap ](https://github.com/jbaubree/vite-plugin-sitemap ) - sitemap and robots generator
2023-12-30 07:49:49 +00:00
### Coding Style
- Use Composition API with [`<script setup>` SFC syntax ](https://github.com/vuejs/rfcs/pull/227 )
2024-01-03 01:47:42 +00:00
- [ESLint ](https://eslint.org/ ) with [@antfu/eslint-config ](https://github.com/antfu/eslint-config ), single quotes, no semi
2023-12-30 07:49:49 +00:00
### Dev tools
- [TypeScript ](https://www.typescriptlang.org/ )
- [Vitest ](https://github.com/vitest-dev/vitest ) - Unit testing powered by Vite
- [pnpm ](https://pnpm.js.org/ ) - fast, disk space efficient package manager
- [Netlify ](https://www.netlify.com/ ) - zero-config deployment
- [VS Code Extensions ](./.vscode/extensions.json )
- [Volar ](https://marketplace.visualstudio.com/items?itemName=Vue.volar ) - Vue 3 `<script setup>` IDE support
2024-12-09 12:43:53 +00:00
- [Unocss ](https://marketplace.visualstudio.com/items?itemName=antfu.unocss ) - UnoCSS for VS Code
- [Goto Alias ](https://marketplace.visualstudio.com/items?itemName=antfu.goto-alias ) - Go to Definition following alias redirections
2023-12-30 07:49:49 +00:00
- [Iconify IntelliSense ](https://marketplace.visualstudio.com/items?itemName=antfu.iconify ) - Icon inline display and autocomplete
2024-12-09 12:43:53 +00:00
- [File Nesting ](https://marketplace.visualstudio.com/items?itemName=antfu.file-nesting ) - Config of File Nesting for VS Code
2024-03-29 11:20:31 +00:00
- [i18n Ally ](https://marketplace.visualstudio.com/items?itemName=lokalise.i18n-ally ) - All in one i18n support
2024-12-09 12:43:53 +00:00
- [ESLint ](https://marketplace.visualstudio.com/items?itemName=dbaeumer.vscode-eslint ) - Eslint support
- [Better JSON5 ](https://marketplace.visualstudio.com/items?itemName=blueglassblock.better-json5 ) - JSON5 support
2023-12-30 07:49:49 +00:00
2024-01-03 01:47:42 +00:00
## Try it now
2023-12-30 07:49:49 +00:00
2024-03-28 06:25:57 +00:00
> vue3-vant-mobile requires Node 18+
2023-12-30 07:49:49 +00:00
### GitHub Template
2024-03-28 06:25:57 +00:00
[Create a repo from this template on GitHub ](https://github.com/easy-temps/vue3-vant-mobile/generate )
2023-12-30 07:49:49 +00:00
### Clone to local
If you prefer to do it manually with the cleaner git history
2022-06-22 04:55:17 +00:00
```bash
2024-06-24 03:58:03 +00:00
npx tiged easy-temps/vue3-vant-mobile my-mobile-app
2023-12-30 07:49:49 +00:00
cd my-mobile-app
pnpm i # If you don't have pnpm installed, run: npm install -g pnpm
2022-06-22 04:55:17 +00:00
```
2023-12-30 07:49:49 +00:00
## Checklist
2022-06-22 04:55:17 +00:00
2023-12-30 07:49:49 +00:00
When you use this template, try follow the checklist to update your info properly
2022-06-22 04:55:17 +00:00
2023-12-30 07:49:49 +00:00
- [ ] Change the author name in `LICENSE`
- [ ] Change the title in `index.html`
- [ ] Change the hostname in `vite.config.ts`
- [ ] Change the favicon in `public`
- [ ] Clean up the READMEs and remove routes
2022-06-22 04:55:17 +00:00
2023-12-30 07:49:49 +00:00
And, enjoy :)
## Usage
### Development
2022-06-22 04:55:17 +00:00
2024-01-03 01:47:42 +00:00
Just run and visit < http: / / localhost:3000 >
2022-06-22 04:55:17 +00:00
```bash
2022-10-25 03:03:31 +00:00
pnpm dev
2022-06-22 04:55:17 +00:00
```
2023-12-30 07:49:49 +00:00
### Build
To build the App, run
2022-06-22 04:55:17 +00:00
```bash
2022-10-25 03:03:31 +00:00
pnpm build
2022-06-22 04:55:17 +00:00
```
2024-01-03 01:47:42 +00:00
2023-12-30 07:49:49 +00:00
And you will see the generated file in `dist` that ready to be served.
2022-06-22 04:55:17 +00:00
2023-12-30 07:49:49 +00:00
### Deploy on Netlify
2022-06-22 04:55:17 +00:00
2023-12-30 07:49:49 +00:00
Go to [Netlify ](https://app.netlify.com/start ) and select your clone, `OK` along the way, and your App will be live in a minute.
2022-06-22 04:55:17 +00:00
2024-09-02 07:08:09 +00:00
## Community 👏
2024-04-21 12:33:18 +00:00
2024-09-02 07:08:09 +00:00
We recommend that [issue ](https://github.com/easy-temps/vue3-vant-mobile/issues ) be used for problem feedback, or [Wechat group ](https://github.com/easy-temps/vue3-vant-mobile/issues/56 ).
2024-04-21 12:33:18 +00:00
2024-05-22 09:33:16 +00:00
## Donation ☕
2024-05-20 14:43:25 +00:00
[Buy Me a Coffee ](https://github.com/CharleeWa/sponsor )
2024-05-22 09:33:16 +00:00
< h2 align = "center" > 💝 Our Sponsors 💝< / h2 >
< p align = "center" >
Your sponsorship will help us continue to iterate on this exciting project! 🚀
< / p >
< p align = "center" >
2024-05-23 03:13:24 +00:00
< a href = "https://github.com/keyFeng" > < img src = "https://avatars.githubusercontent.com/u/52267976?v=4" width = "60px" alt = "keyFeng" / > < / a >
< a href = "https://github.com/ljt990218" > < img src = "https://avatars.githubusercontent.com/u/50509815?v=4" width = "60px" alt = "ljt990218" / > < / a >
2024-06-12 14:28:41 +00:00
< a href = "https://github.com/heked" > < img src = "https://avatars.githubusercontent.com/u/14127731?v=4" width = "60px" alt = "heked" / > < / a >
2024-09-27 05:37:52 +00:00
< a href = "https://github.com/topcnm" > < img src = "https://avatars.githubusercontent.com/u/8057893?v=4" width = "60px" alt = "topcnm" / > < / a >
2024-05-22 09:33:16 +00:00
< / p >
< h2 align = "center" >
💪 Contributors 💪
< / h2 >
< p align = "center" >
Our contributors have made this project better. Thank you! 🙏
< / p >
< p align = "center" >
2024-05-23 03:13:24 +00:00
< a href = "https://github.com/CharleeWa" > < img src = "https://avatars.githubusercontent.com/u/22477554?v=4" width = "60px" alt = "CharleeWa" / > < / a >
< a href = "https://github.com/ljt990218" > < img src = "https://avatars.githubusercontent.com/u/50509815?v=4" width = "60px" alt = "ljt990218" / > < / a >
< a href = "https://github.com/wswmsword" > < img src = "https://avatars.githubusercontent.com/u/26893092?v=4" width = "60px" alt = "wswmsword" / > < / a >
< a href = "https://github.com/weiq" > < img src = "https://avatars.githubusercontent.com/u/1697158?v=4" width = "60px" alt = "weiq" / > < / a >
< a href = "https://github.com/SublimeCT" > < img src = "https://avatars.githubusercontent.com/u/20380890?v=4" width = "60px" alt = "SublimeCT" / > < / a >
< a href = "https://github.com/ReginYuan" > < img src = "https://avatars.githubusercontent.com/u/49477488?v=4" width = "60px" alt = "ReginYuan" / > < / a >
< a href = "https://github.com/smartsf" > < img src = "https://avatars.githubusercontent.com/u/19995400?v=4" width = "60px" alt = "smartsf" / > < / a >
< a href = "https://github.com/Kysen777" > < img src = "https://avatars.githubusercontent.com/u/63892082?v=4" width = "60px" alt = "Kysen777" / > < / a >
< a href = "https://github.com/Leezon" > < img src = "https://avatars.githubusercontent.com/u/38120280?v=4" width = "60px" alt = "Leezon" / > < / a >
< a href = "https://github.com/AlphaYoung111" > < img src = "https://avatars.githubusercontent.com/u/54132313?v=4" width = "60px" alt = "AlphaYoung111" / > < / a >
< a href = "https://github.com/leo4developer" > < img src = "https://avatars.githubusercontent.com/u/15160478?v=4" width = "60px" alt = "leo4developer" / > < / a >
< a href = "https://github.com/InsHomePgup" > < img src = "https://avatars.githubusercontent.com/u/47906083?v=4" width = "60px" alt = "InsHomePgup" / > < / a >
< a href = "https://github.com/wowping" > < img src = "https://avatars.githubusercontent.com/u/137802961?v=4" width = "60px" alt = "wowping" / > < / a >
< a href = "https://github.com/ChunyuPCY" > < img src = "https://avatars.githubusercontent.com/u/21986942?v=4" width = "60px" alt = "ChunyuPCY" / > < / a >
< a href = "https://github.com/qiyue2015" > < img src = "https://avatars.githubusercontent.com/u/11554433?v=4" width = "60px" alt = "qiyue2015" / > < / a >
< a href = "https://github.com/pyQianYi" > < img src = "https://avatars.githubusercontent.com/u/57526688?v=4" width = "60px" alt = "pyQianYi" / > < / a >
2024-06-24 04:01:12 +00:00
< a href = "https://github.com/xyy94813" > < img src = "https://avatars.githubusercontent.com/u/17971352?v=4" width = "60px" alt = "xyy94813" / > < / a >
2024-08-18 14:33:37 +00:00
< a href = "https://github.com/faukwaa" > < img src = "https://avatars.githubusercontent.com/u/133618995?v=4" width = "60px" alt = "faukwaa" / > < / a >
2024-08-29 16:17:13 +00:00
< a href = "https://github.com/chensongni" > < img src = "https://avatars.githubusercontent.com/u/18071921?v=4" width = "60px" alt = "chensongni" / > < / a >
2023-12-14 02:43:16 +00:00
< / p >
2024-05-23 03:13:24 +00:00
## License
[MIT ](./LICENSE ) License