Skip to content

dragonfly6373/electron-app-react-template

Repository files navigation

Electron + TypeScript + React

Boilerplate for a project using Electron, React and Typescript.

Installation

Use a package manager of your choice (npm, yarn, etc.) in order to install all dependencies

// install electron dev-tools dependencies
npm install -D typescript file-loader @types/electron-devtools-installer @types/jest @types/react @types/react-dom @types/styled-components

// install build tools and plugins develop-dependencies
npm install -D @babel/core @babel/plugin-transform-runtime @babel/preset-env @babel/preset-react @babel/preset-typescript @electron-forge/cli @electron-forge/maker-deb @electron-forge/maker-rpm @electron-forge/maker-squirrel @electron-forge/maker-zip @electron-forge/plugin-webpack @typescript-eslint/eslint-plugin @typescript-eslint/parser babel-loader cross-env electron eslint eslint-config-prettier eslint-config-standard eslint-plugin-import eslint-plugin-node eslint-plugin-prettier eslint-plugin-promise eslint-plugin-react eslint-plugin-standard

// install testing dependencies
npm install -D jest npm-run-all prettier ts-jest

// install build tools dependencies
npm install -D @marshallofsound/webpack-asset-relocator-loader @testing-library/jest-dom @testing-library/react --legacy-peer-deps

Usage

Just run start script.

npm start
// or
yarn start

Packaging

To generate the project package based on the OS you're running on, just run:

npm run package
// or
yarn package

Technical Refferences

ipcMain:

  • ipcMain
  • IPC - Share Memory Model and Message Passing Model

Electron Storage:

  • electron-store
  • safeStorage - allows access to simple encryption and decryption of strings for storage on the local machine.
  • nedb - local data storage example

Contributing

Pull requests are always welcome 😃.

License

MIT

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published