Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/electron-vite/electron-vite-boilerplate
📚 Really simple Electron + Vite boilerplate.
https://github.com/electron-vite/electron-vite-boilerplate
boilerplate electron esbuild serialport sqlite3 vite webpack
Last synced: 3 months ago
JSON representation
📚 Really simple Electron + Vite boilerplate.
- Host: GitHub
- URL: https://github.com/electron-vite/electron-vite-boilerplate
- Owner: caoxiemeihao
- License: mit
- Created: 2021-02-21T13:16:39.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2024-05-01T09:40:08.000Z (6 months ago)
- Last Synced: 2024-05-19T09:29:33.977Z (6 months ago)
- Topics: boilerplate, electron, esbuild, serialport, sqlite3, vite, webpack
- Language: TypeScript
- Homepage:
- Size: 6.65 MB
- Stars: 201
- Watchers: 4
- Forks: 28
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- fucking-awesome-vite - electron-vite-boilerplate - Support SerialPort, SQLite3 and node C/C++ addons. (Get Started / Templates)
- awesome-vite - electron-vite-boilerplate - Support SerialPort, SQLite3 and node C/C++ addons. (Get Started / Templates)
README
# electron-vite-boilerplate
🥳 Really simple `Electron` + `Vite` boilerplate.
![screenshort.png](https://github.com/electron-vite/electron-vite-boilerplate/blob/main/public/screenshort.png?raw=true)
## Features
📦 Out of the box
🚀 Quick Start of [vite-plugin-electron](https://github.com/electron-vite/vite-plugin-electron)
🎯 Based on the official [template-vanilla-ts](https://github.com/vitejs/vite/tree/main/packages/create-vite/template-vanilla-ts), less invasive## Run Setup
```sh
# clone the project
git clone https://github.com/electron-vite/electron-vite-boilerplate.git# enter the project directory
cd electron-vite-boilerplate# install dependency
npm install# develop
npm run dev
```## Directory
```diff
+ ├─┬ 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
```## Be aware
🚨 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](https://github.com/electron-vite/vite-plugin-electron/tree/main/packages/electron-renderer#config-presets-opinionated).
```diff
# vite.config.tselectron({
- renderer: {}
})
```## FAQ
- [dependencies vs devDependencies](https://github.com/electron-vite/vite-plugin-electron/tree/main/packages/electron-renderer#dependencies-vs-devdependencies)
- [Using C/C++ native addons in Electron-Renderer](https://github.com/electron-vite/vite-plugin-electron/tree/main/packages/electron-renderer#load-nodejs-cc-native-modules)
- [Node.js ESM packages](https://github.com/electron-vite/vite-plugin-electron/tree/main/packages/electron-renderer#nodejs-esm-packages) (e.g. `execa` `node-fetch`)## 🍵 🍰 🍣 🍟