Code Monkey home page Code Monkey logo

electron-react-template's Introduction

Electron React Template

Easy-to-understand-and-use boilerplate code for creating an Electron desktop app simply using Reactjs. Includes React Router.
This project was bootstrapped with Create React App, Electron, and electron-builder.

Build Electron App With React - Video Tutorial

Video Tutorial at YouTube

Usage

  1. Clone this repository.
git clone https://github.com/TarunKumar29/electron-react.git <your-project-name>
  1. If you havent already, install Yarn globally.
npm install -g yarn
  1. Navigate into project root and install dependencies.
cd <your-project-name> && npm install
  1. Run dev server.
npm run start

Deploy to Desktop

  1. Run the build process
npm run build
  1. Go into your project folder using your file explorer. Navigate to the dist folder and open it. Then double-click <your-project-name> Setup 0.1.0. Your app should open and there should now be an icon on your desktop for this app.

Use a Custom Icon

Add a 256 x 256 .png or .ico image in your public folder. It should be either icon.ico or icon.png. Update the icon property in your package.json if necessary. Currently, it uses an image called icon.png, which is a graphic of a coffee cup. You'll only see this in production. For more info, see the electron-builder documentation

Errors to ingnore while using the template -

  1. Errors showing the modules are deprecated. You can safely use the template even after those warnings or errors (though it is advisable to update it).

Example -

...
npm WARN deprecated @hapi/[email protected]: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated...

(Note: However these types of messages are not expected as all the modules are updated frequently. :) )

  1. Errors related to fsevents can be ignored if it is use in computer which is not a mac. (If any error related to fsevents happens on mac, please file a issue !)

Credits to (for making the initial commits of the repo) -

@willjw3 | https://github.com/willjw3

electron-react-template's People

Contributors

dependabot[bot] avatar quirklessshinobi avatar yourself29 avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Forkers

thedogecraft

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.