Тёмный

Electron with React JS under 40 min! 

Eincode
Подписаться 3,5 тыс.
Просмотров 84 тыс.
50% 1

More Courses: academy.eincode.com/
Full Course: academy.eincode.com/courses/e...
Github Repo: github.com/Jerga99/electron-r...
Blog Post: eincode.com/blogs/electron-re...
Electron:
If you can build a website, you can build a desktop app. Electron is a framework for creating native applications with web technologies like JavaScript, HTML, and CSS. It takes care of the hard parts so you can focus on the core of your application.
React JS:
React makes it painless to create interactive UIs. Design simple views for each state in your application, and React will efficiently update and render just the right components when your data changes.
Firebase:
Firebase gives you functionality like analytics, databases, messaging, and crash reporting so you can move quickly and focus on your users.
-- Course Overview --
In the first section, you are going to learn what Electron JS is and what features it offers. We will learn basic concepts like the main and renderer process among many others. The UI part of the application will be handled by React Library, we will install React and we will prepare Webpack which will be responsible for bundling of our source files.
In the second section, we will create multiple views like Home, Chat, Settings views, and many others. We will integrate the routing system so we can navigate between the views. State management of the application will be handled by redux architecture and the data will be stored in the Firestore database. I will show you how to use Firestore queries, how to fetch and manipulate data.
The third section will be dedicated to authentication. We will create a login and register form and I will teach you how to handle errors coming from Firestore. Only logged in users will have full access to our application.
In the fourth section, we will explain redux middleware and we will work on the Notification feature. The application will be able to detect whether the user is offline or online. Connection changes will be displayed by the Notification system.
In the fifth section, we will be working on chat management features. The first one will be chat create functionality. After the chat will be created it will be displayed in the list of available chats. Upon clicking on the join button chat will be joined and added into the list of joined ones. The online status of a user will be displayed when the user will be joined in the chat. A green dot will indicate that the user is online, the gray dot will be reserved for offline status.
In the sixth section, we will be working on the messaging feature. Users will be able to write a message and send it out to our Firestore database. Our Application will be able to detect new messages and display them in the current active chat. Messages will be synchronized amongst many active clients.
Next, we will work on the settings view. Users will be able to change the global settings of our application. Settings will affect mostly the theme of our application and the way how Notifications work. We will store settings in local storage so we are able to retrieve them in the next load of our application.
In the seventh section, we will work on small adjustments in the Electron environment. We will create an application menu with multiple settings. We will add a tray icon to the top or bottom menu of our operating system. We will change the icon of our application and we will start working on the splash screen. The splash screen will be displayed before our main application will be fully loaded. In the last lectures, we will prepare the build configuration and will build up our application into executable files that can run on Windows, Linux, and macOS.
That’s it from the preview. There is much more covered in the lectures. I hope you like the application we are going to work on and I hope to see you in the course.

Опубликовано:

 

21 сен 2020

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 92   
@cindy8077919
@cindy8077919 3 года назад
TL;DR For people who don't like to type: All the things you'll need to install npm install --save electron react react-dom npm install --save-dev @babel/core @babel/preset-env @babel/preset-react css-loader style-loader sass-loader babel-loader webpack webpack-cli electron-reload For Window 10 users: If you didn't see notifications on button click - check your notification settings & remember to turn off 'Focus Assist'
@alessandrof.m.9287
@alessandrof.m.9287 3 года назад
Awesome man, I came here just to run react+electron because i already have some react projects, but you open my mind to electron with this simple notification at the end. Amazing!
@ewertoncassianoxavier3490
@ewertoncassianoxavier3490 2 года назад
This isn't a simple video, but a masterpiece! Thank you very much for this amazing lesson!
@mattb3685
@mattb3685 2 года назад
This video has been a lifesaver for me. I've had a ton of trouble for whatever reason, setting up an electron app, setting it up with React, then trying to configure webpack or whatever else, trying to set it up with Sqlite3 and not being able to, then running around trying to download boilerplate templates, Googling errors, additional npm packages... This is my favorite video that I've found on getting started with Electron. Perfect balance between brevity and depth. You clearly have expertise on the subject and on the ecosystem in general, it's not just copied information available everywhere, you explain things just enough rather than leaving things for granted, like you totally get your target audience. Everything works as advertised. I haven't had to go off and troubleshoot or Google additional things because parts of it were outdated. No bloat, no downloading or copying and pasting anything crazy, or deprecated/unmaintained/sketchy (go and add this npm package with
@mikelexp
@mikelexp 2 года назад
Wow, I've learned A LOT of really useful info in just 36 minutes. Amazing work Filip, thanks!!
@giffarialfarizy7310
@giffarialfarizy7310 2 года назад
Wow, this is great tutorial! Your explanation is not too theoretically but the fundamental is covered in the same time. I also really like that very simple boilerplate. Thank you!
@jester_x18
@jester_x18 2 года назад
Thanks, man! Over 1 thousand articles, quickstarts and videos, you are the first one who explained electron-react solution and how it should work.
@louisgirardin2030
@louisgirardin2030 3 года назад
Thx for the detailed walkthrough. It was quite insightful. Made lot of sense and good rhythm.
@reinioyeah5467
@reinioyeah5467 2 года назад
Really really great tutorial👍 The right amount of theory and practice. I just bought the full course because i am sure it will save me a lot of time learning this things.
@amingrateful7661
@amingrateful7661 3 года назад
You really do have a great grasp on this stuff. I'm kinda jealous!
@aenkas
@aenkas 3 года назад
thats the best tutorial for building pure electron-react app! thanks!
@ProjectOceanFloor
@ProjectOceanFloor 2 года назад
This is the cleanest way to implement your own pure JS scripts into an Electron app with a frontend framework/library that I have found - This process worked in December 2021 even though the first Google search was a medium article implying Electron only worked with TypeScript. Tysm.
@reactnativecoder
@reactnativecoder 2 года назад
Great boilerplate actually you pointed out from scratch which is amazing
@marcosmercedesn
@marcosmercedesn 3 года назад
This video was sharp, straight to the point
@sadcandy5834
@sadcandy5834 2 года назад
thans for this great work! I was complicated with those docs of Electron React Boilerplate until I find this! finally figure out these settings , ESM stuffs and structure of the project
@shinobigamer3589
@shinobigamer3589 2 года назад
You have saved me so much time with this tutorial. Thank you
@WornOffKeys
@WornOffKeys 2 года назад
Great tutorial, just purchased your electron course after watching this.
@Ab-on5dj
@Ab-on5dj 2 года назад
Thanks for this nice tutorial. I have side-topic question if you don't mind. Do you record your voice alongside with the screen at the same time, or you do it seperatly? Thank you
@bilaleme
@bilaleme 3 года назад
Some people simply have art of excellent explanation. And you are one of them. +1
@julian16180
@julian16180 Год назад
Amazing Video so far. What do I need to do different/ watch out for, when I want to use TypeScript with React, not JavaScript?
@b.c.palmer2824
@b.c.palmer2824 3 года назад
Hi @Eincode, the idea of integrating react with electron is pretty new to me, but I followed your instructions twice and I'm getting an error: "Uncaught ReferenceError: reactDOM is not defined". There are only three lines in my index.js, and they look exactly the same as yours, except the id I'm targeting has a different name. I'm on electron 11.1.0 and Node 14.15.2. Any common causes?
@codex1758
@codex1758 2 года назад
Awesome video man, is it possible to use other modules such as framer-motion and tailwind css??
@Ebizzill
@Ebizzill 3 года назад
BROH!! if YOU'RE the reason why i get this gig.... I'm donating to this channel
@enebishsundui6477
@enebishsundui6477 Год назад
Great video, thank you very much. How can we notify from main to React component?
@aburk3146
@aburk3146 2 года назад
great tutorial. Once I finish my app, how do I deploy this and have a working app?
@otisrancko
@otisrancko Год назад
Greeeeaaaat video for Electron basics😉
@shubhamp_web
@shubhamp_web 3 года назад
Thanks for this video 🖥
@8ashastiraagavk.g760
@8ashastiraagavk.g760 3 года назад
hey mam good thing for writing the boilerplate for the html first install Emmet and write exclamation mark and hit the tab and you will get full boilerplate of html
@leonh2140
@leonh2140 Год назад
Cool video, thanks! But I'm wondering how to package the app? Since this is the main reason for using Electron
@crimps.on.slopers
@crimps.on.slopers Год назад
Ok so why doesnt this guy have 1 million followers. Very clear and consise. You can tell he knows what hes doing. Everyone could relate to spam clearing console. Made me laugh everytime. And went at a very good pace.
@meetpanchal8809
@meetpanchal8809 Год назад
Thanks for this masterpiece.
@rockNbrain
@rockNbrain 2 года назад
great job dude! tks a lot!!!
@drjones694
@drjones694 Год назад
Wish you packaged this up at the end You showed if dev run this way but when you make do you need to host the react app or does it run local to where ever the app starts?
@kuma4824
@kuma4824 3 года назад
great video :)
@hmodarres
@hmodarres 3 года назад
nice! super helpful
@854gabryel
@854gabryel 3 года назад
Do you know if there's another way to solve `Cannot use import statement outside of a module` error without adding webpack?
@haddadimohamedmanil3999
@haddadimohamedmanil3999 3 года назад
man you are awsome, i m a fan
@shahbazshaikh1725
@shahbazshaikh1725 3 года назад
How to build the project, cant find any suitable answer on the internet. Please help.
@ggyoug
@ggyoug Год назад
Real good!!! Thanks!!!
@diyshow888
@diyshow888 Год назад
Still works in 2023 , thank you so much Master
@rabahmahboulgravity5991
@rabahmahboulgravity5991 Год назад
this is working thank you it wass ammazing
@MyStockz
@MyStockz 2 года назад
Hello! Hope you are well! I got an error on electron.notificationApi.sendNotification part. It says, Cannot read properties of undefined Help!!! Is it a preload.js problem?
@lilcorndog
@lilcorndog 3 года назад
Could you do a tutorial on contextBridge/ipcRenderer/Main. Having trouble understanding how to pass my data back to component.
@mateusteixeira7129
@mateusteixeira7129 3 года назад
I'm getting this same problem. Have you already solved?
@lilcorndog
@lilcorndog 2 года назад
@@mateusteixeira7129 sort of. but still have tons of questions. I tried using discord to get help but it seems hard to get a question answered.
@mahendranath2504
@mahendranath2504 2 года назад
Thank you so much 👍🏼🎉🙏❤️
@tkragelj
@tkragelj 3 года назад
Nice tutorial - first one that allowed me to actually get to working electron+react solution (being complete node newbie). However I got stuck at the end, when adding preload stuff - as soon as I do that watch script starts spitting out error: ERROR in ./node_modules/enhanced-resolve/lib/ResolverFactory.js 118:9-26 Module not found: Error: Can't resolve 'pnpapi' in 'C:\Users\Tomaz\Documents\Projekti\Electron eact-test3 ode_modules\enhanced-resolve\lib' I do use newer versions of webpack, though got similar results using the same as in this tutorial... I didn't find any solution on internet, do you have a hint perhaps?
@cindy8077919
@cindy8077919 3 года назад
That's exactly the issue I faced! What worked for me was to remove the line "import { electron } from "webpack" when you typed electron.notificationApi.sendNotification ... react automatically try to find where that electron comes from and import that, remove that line solved the issue for me
@davidpaley2865
@davidpaley2865 2 года назад
Hey bro, how can i enable nodeintegration to run my node js scripts, when i set nodeintegration to true and contextisolation to false, webpack stops working. And how can i build app?
@masterbluecat3416
@masterbluecat3416 2 года назад
very good keep going
@Ouchie
@Ouchie 3 года назад
Electron crashed when making changes in the main.js file with electron-reload with isDev variable if (isDev) { require('electron-reload')(__dirname, { electron: path.join(__dirname, 'node_modules', '.bin', 'electron') }) } The error: Uncaught exception: Error: spawn node_modules\.bin\electron ENOENT Using windows 10
@geek7807
@geek7807 2 года назад
If bundle loaded from "./build/js/app.js" and "./src/js/App.js" return error, how I can use live reloaded?
@MyStockz
@MyStockz 2 года назад
Hey! Did you found a solution?
@abdulqureshi7108
@abdulqureshi7108 2 года назад
Hey bro, how to build this app with react. in the build, react not working.
@csfx69
@csfx69 3 года назад
How to build the app at the end?
@wenn-1234
@wenn-1234 3 года назад
Hi, how do I build this project to an exe file using Electron builder?
@csfx69
@csfx69 3 года назад
i need to know this too
@vudinhcong
@vudinhcong 2 года назад
I can't use webpack, reactjs with puppeteer ?, How to use it ? Thanks
@TheNamesJT
@TheNamesJT 3 года назад
I keep getting this when running npm start " To run a local app, execute the following on the command line: $node_modules\electron\dist\electron.exe path-to-app"
@Harikanth
@Harikanth 8 месяцев назад
I am getting error "supported in React 18. Use createRoot instead. Until you switch to the new API, your app will behave as if it's running React 17." My react version is 18.2.0. How to fix this? Any help is appreciated.
@simonplm9718
@simonplm9718 3 года назад
thanks!
@kuma4824
@kuma4824 3 года назад
development mode causes an error in the console, because the development code produces code with the eval function and this is against the Content Security Policy. How could i fix it? or I just use the "production" mode.
@Eincode
@Eincode 3 года назад
Hello Kurma, you can place 'unsafe-eval' option into index.html in development,
@kuma4824
@kuma4824 3 года назад
@@Eincode keeps popping up: "Electron Security Warning". In webpack there is a section on how to enable csp, but I don't really understand how to add "__webpack_nonce__". Hopefully you can read it, maybe you do understand. Still, thank you, you are one of the few people who really uses (or tries) good practices with this framework.
@psol1001
@psol1001 2 года назад
sorry, I have some troubles using electron-reload library, this is not workin, I don't know what to do :(
@sergheigarau514
@sergheigarau514 3 года назад
Hi thanks for the video, very interesting. I tried to integrate react-bootsrap-table, both the new and the old version. Unfortunately there are problems, it does not work and it is difficult to understand why. Could you make a video where you try this electron + react + react-bootstrap-table setup? Thank you
@novandosantosa3621
@novandosantosa3621 3 года назад
after i change my index.js with ReactDOM.render(, document.getElementById('root')). My app can't be updated. It keep showing "Hello React App". It should be "I am app component", even i refreshed the page hundred times. Could you help me please?
@hassanmanaii8914
@hassanmanaii8914 3 года назад
I don't know why but you need to run watch before run start
@Akash-xv5sk
@Akash-xv5sk 9 месяцев назад
How to logout a user when i click window close button?
@kwabenaboateng7405
@kwabenaboateng7405 Год назад
But how do you create a multi-page app with this?
@variousviz
@variousviz Год назад
How to add tailwind to project?
@codeswithankit4316
@codeswithankit4316 3 года назад
Great
@ArvindSingh-wj7vy
@ArvindSingh-wj7vy 27 дней назад
require("electron-reload")(__dirname, { electron: path.join(__dirname, "node-modules", ".bin", "electron"), }); This line is throwing error, help please/
@Ibrahim-oc5ql
@Ibrahim-oc5ql 2 года назад
Filip Thanks buds
@mohammadsaquib3373
@mohammadsaquib3373 3 года назад
contextIsolation : true gives error for require file
@orhanabbasov6870
@orhanabbasov6870 3 года назад
Couple questions: 1. How to send ipc from main to renderer 2. How to compile it? Which files need to build and which files no need. And the tutorial is great. I've already built a Electron app from scratch, but without react. It's on production already.
@Eincode
@Eincode 3 года назад
Hello Han, congratz to your application! You can expose ipc in preload.js as explained in the video. You need to build only JS files included in src folder.
@vivekreddy8864
@vivekreddy8864 3 года назад
babel will be able
@codiumyt
@codiumyt 3 года назад
Why do you say every noun as plural? Terminals, editors etc...
@nerdion1911
@nerdion1911 3 года назад
Don't be karen
@codiumyt
@codiumyt 3 года назад
@@nerdion1911 I was just curious…
@nerdion1911
@nerdion1911 3 года назад
@@codiumyt just kidding, no worries. His tutorial saved my life yesterday
@BO-nn9up
@BO-nn9up 2 года назад
kinda habit at least he speaking english.. just thanks for that
@stancobridge
@stancobridge 3 года назад
Module not found: Error: Can't resolve 'react Module not found: Error: Can't resolve 'react-dom' I did npm i --save-dev @babel/core @babel/preset-env @babel/preset-react css-loader style-loader sass-loader sass webpack webpack-cli I don't know what am missing
@stancobridge
@stancobridge 3 года назад
Fixed by instaling react and react-dom
@priyankamore1458
@priyankamore1458 Год назад
babel will be able..🤣🤣🤣🤣🤣🤣🍹..
@user-ju8bs8co1t
@user-ju8bs8co1t 10 месяцев назад
CSS DOESNT WORK!
@muhammadsanjarafaq914
@muhammadsanjarafaq914 Год назад
You should skip useless details like terminal (mkdir) and meta tags. Could have just use !(bang) to write HTML. Makes the video longer.
@malikcatyes656
@malikcatyes656 2 года назад
React 18 introduces new root API ( ReactDOM.createRoot ) In src/js/index.js to avoid some errors from react. import React from "react"; import ReactDOM from "react-dom/client"; import App from "./App"; import "./index.scss"; const container = document.getElementById("root"); const root = ReactDOM.createRoot(container); root.render();
@waleedkhan-cw2vy
@waleedkhan-cw2vy Год назад
npm install --save-dev @babel/core @bable/preset-env @bable/preset-react css-loader style-loader sass-loader sass webpack webpack-cli
Далее
Create a Desktop App With JavaScript & Electron
1:11:48
Просмотров 322 тыс.
UI Libraries Are Dying, Here's Why
13:28
Просмотров 264 тыс.
ElectronJS Crash Course 2022
1:30:39
Просмотров 62 тыс.
React.js just got a major upgrade
14:38
Просмотров 88 тыс.
Tauri in 100 Seconds
2:40
Просмотров 636 тыс.