An Electron + Vue 3 starter project setup with Vite, Typescript, Vue-Router, Pinia, Eslint, Prettier, Tailwind CSS, and some custom preferences.
This repository is an extended version of the simple one.
π¦ Out of the box
π― Based on the official template-vue-ts, less invasive
π± Extensible, really simple directory structure
πͺ Support using Node.js API in Electron-Renderer
π© Support C/C++ native addons
π₯ It's easy to implement multiple windows
π configured with Eslint & Prettier
π Vue router support
π Pinia state management
π TailwindCSS (Dark mode support)
π VueUse
π Easy dependency update with taze
π I18n support - multiple locales
npm i
or,
pnpm i --shamefully-hoist
In development mode,
npm run app:dev
or,
pnpm run app:dev
In preview mode,
npm run app:preview
or,
pnpm run app:preview
To build for production,
npm run app:build
or,
pnpm run app:build
+ βββ¬ electron
+ β βββ¬ main
+ β β βββ index.ts entry of Electron-Main
+ β βββ¬ preload
+ β βββ index.ts entry of Preload-Scripts
βββ¬ src
β βββ main.ts entry of Electron-Renderer
βββ index.html
βββ package.json
βββ vite.config.ts
π¨ By default, this template integrates Node.js in the Renderer process. If you don't need it, you just remove the option below. Because it will modify the default config of Vite.
# vite.config.ts
export default {
plugins: [
- // Use Node.js API in the Renderer-process
- renderer({
- nodeIntegration: true,
- }),
],
}