Skip to content

Commit 278e810

Browse files
Add Electron setup instructions to README
Added instructions for setting up an Electron application with React, Vite, and Tailwind to the README.
1 parent c272aed commit 278e810

1 file changed

Lines changed: 26 additions & 0 deletions

File tree

README.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ Resources to quickly get started and running for different domains.
55
- [Node](#node)
66
- [FE (Next JS)](#fe-next-js)
77
- [BE](#be)
8+
- [Electron (React + Vite + Tailwind)](#electron-react-vite--tailwind)
89
- [WSL (Windows Subsystem for Linux)](#wsl-windows-subsystem-for-linux)
910
- [Docker](#docker)
1011
- [AI , LLMs , MCP](#ai--llms--mcp)
@@ -103,6 +104,31 @@ npm -v # Should print "11.6.2".
103104
You can use all the resources available online, youtube tutorials/videos, GPT, go docs anything to create it.
104105
Bonus: Host this application in docker.
105106

107+
## Electron (React + Vite + Tailwind)
108+
109+
1. Install electron forge with vite and typescript using ```npx create-electron-app@latest my-app --template=vite-typescript```
110+
2. Install react using ```npm install react react-dom``` ```npm install -D @types/react @types/react-dom```
111+
3. Install tailwind using official postCSS documentaion https://tailwindcss.com/docs/installation/using-postcss
112+
4. In renderer.tsx put:
113+
```
114+
import React from "react"
115+
import ReactDOM from "react-dom/client"
116+
import "./index.css"
117+
118+
function App() {
119+
return <h1 className="bg-amber-950 text-red-800">Hello Electron + Vite + React</h1>
120+
}
121+
ReactDOM.createRoot(document.getElementById("root")!).render(<App />)
122+
```
123+
5. Add
124+
```
125+
<div id="root"></div>
126+
<script type="module" src="/src/renderer.tsx"></script>
127+
```
128+
to index.html
129+
6. ```npm start```
130+
131+
106132
## WSL (Windows Subsystem for Linux)
107133

108134
1. Install WSL by running the following command in PowerShell in administrator mode by right-clicking and selecting "Run as administrator"

0 commit comments

Comments
 (0)