Live Netlify demo
Live Vercel demo
-
โก๏ธ Vue 3
-
๐ File based routing
-
๐ Layout system
-
๐ฒ PWA
-
๐จ Windi CSS
-
๐ I18n ready
-
๐ Markdown Support
-
๐ฅ Use the new
<script setup>
syntax -
๐ฅ APIs auto importing
-
๐จ Server-side generation (SSG) via vite-ssg
-
๐ฆพ TypeScript, of course
-
๐ฆ Critical CSS via critters
-
๐๏ธ SCSS support
-
๐ฎ๐ป Format and Lint with VSCode and CLI
- ๐พ Eslint, Import Sort*, Markdownlint, Prettier and, Stylelint.
-
๐ค Standards checking with pre-commit hooks. Test validation on pre-push with Husky
-
โ๏ธ Component and end-to-end testing with Cypress
-
๐ค GitHub Actions and GitLab CI (wip)
-
โ๏ธ Deploy on Netlify, zero-config - See Netlify Deployment
-
โ๏ธ Deploy on Vercel - See Vercel Deployment
*CLI only. VSCode plugin does not support configuration files.
iconify
- use icons from any icon sets ๐Icรดnesunplugin-icons
- icons as Vue components
pinia
vue-router
vite-plugin-pwa
vite-plugin-windicss
vite-plugin-md
vue-i18n-next
vueuse
unplugin-vue-components
unplugin-auto-import
- Alias
@
to<rootDir>
- Alias
~
to<rootDir>/src
a.k.a.<srcDir>
- Predefined and fully typed global variables:
VITE_APP_VERSION
is read frompackage.json
version at build timeVITE_APP_BUILD_EPOCH
is populated asnew Date().getTime()
at build time
typescript
cypress
- E2E Testingpnpm
- fast, disk space efficient package managervite-ssg
- Server-side generationcritters
- Critical CSS
recommended vscode extensions
- Near IDE experience on VSCode
This template is strongly opinionated with my personal preferences and feature sets. It is a fork of the original template created by @antfu and also takes inspiration from vitesse-stackter made by @shamscorner.
For an up-to-date list of official and community contributions to the vitesse ecosystem
, we recommend
checking the official repository's variations section.
Create a repo from this template on GitHub.
If you prefer to do it manually with the cleaner git history
npx degit FranciscoKloganB/vitesse-enterprise my-vitesse-enterprise-app
cd my-vitesse-enterprise-app
pnpm i # If you don't have pnpm installed, run: npm install -g pnpm
When you use this template, try follow the checklist to update your info properly
- Select your git repository of choice
- Remove
vercel.json
ornetlify.yml
depending on your deployment provider. - Rename
name
field inpackage.json
- Change the author name in
LICENSE
- Change the title in
App.vue
- Change the favicon in
public
- Clean up the READMEs and remove routes
- Bump project dependencies (e.g.: dependabot) - We update them on a best-effort-basis, every now and then.
Run and visit http://localhost:4000
pnpm dev
pnpm lint
# Interactive test run
pnpm test:components
pnpm test:e2e
# Headless ( can run both in one step with: pnpm test:ci )
pnpm test:ci:components
pnpm test:ci:e2e
# Ouputs files to dist folder. Ready to be served in SPA mode.
pnpm build:prod
# Outputs files to dist folder which passed through the Vite SSG pipeline. Ready to be served.
pnpm build:prod:ssg
# Runs project locally with files from dist folder
pnpm preview
# Can also run locally with HTTPS (may require sudo)
pnpm preview:https
- Create separate folder for each module and place them under
/src
folder - The following folders are auto imported within each module
components/
modules/
pages/
stores/
- Place all the layouts in the
core/layouts
folder - Place all the custom styles in the
core/assets/styles
folder and import them intomain.{css,scss}
Go to Netlify and select your clone, OK
along the way,
and your App will be live in a minute.
Vercel has some short-commings regarding pnpm
based projects. After creating
and importing the project on Vercel dashboard you will
need to navigate to the project settings and override the Build Command
and Install Command
respectively, with the following bash commands:
# Build Command
npx pnpm i --store=node_modules/.pnpm-store && npx pnpm run build:prod:ssg
# Install Command
npm i -g pnpm && pnpm -i
Alternatevely, for zero configuration on import you need to alter package.json
scripts to have
a build
and install
entries with the commands above.
On top of what was mentioned by Anthony Fu in the original post, working in conjunction with others often requires strict styling rules. Creating a seamless developer experience across VSCode, CLI and CI/CD consumes time. Vue, Vite and, Vitesse, are amazing tools for web developmen and are now my go to choices for development. To avoid repeating myself over and over again for to get this configurations going, I decided to fork Vitesse repository and create a baseline project for my own (or other people) use, enabling us to be vite. Pun intended.
If you notice any bug, inconsistency or change for improvement, feel free to either create an issue so that I may try to fix it later or to propose a pull request with the changes.