SlideShare a Scribd company logo
Volodymyr Dubenko
Materialise
Node.js for desktop development
(based on Electron library)
About me
Was working as Asp.net developer, tech lead, team
lead, project and product manager
Now: Architect at Materialise
Node.js for desktop development
(based on Electron library)
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
Need: Product for manufacturing
Technology
Experiment!
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
Electron
… and many more
Visual Studio Code
Cross-platform
Single code for all platforms
Community
24 460 GitHub repositories
1875 npm packages
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
install Node.js & Git
$ npm install -g electron-forge
$ electron-forge init hello-world
$ cd hello-world
$ electron-forge start
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
Mainprocess
Renderer process #1
Renderer process #2
Renderer process #3
UI development
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
$ npm install electron –g
$ npm install aurelia-cli –g
$ au new electron-au-app
$ npm install electron --save-dev
Add to index.html
Modify package.json
electron quick start -> electron-index.js
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
$ au run --watch
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
Debugging
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
Communication
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
Main process Renderer process
A microservice
>> Testing
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
Main process Renderer process
Test runner Jasmine Karma
Test framework Jasmine Jasmine
Debugging VS Code Chrome
Packaging
AU
• Transpile
• Markup, CSS
• Bundle
Electron • Build config
• Pack
electron-builder
Challenges
WCF + NTLM authentication =
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
Next challenge -
documents
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
Володимир Дубенко "Node.js for desktop development (based on Electron library)"
From what to start
Help resources
electronjs.org
Awesome electron
electron-forge
Thanks!

More Related Content

PDF
Евгений Жарков "React Native: Hurdle Race"
PDF
"How to Use Bazel to Manage Monorepos: The Grammarly Front-End Team’s Experie...
PDF
"13 ways to run web applications on the Internet" Andrii Shumada
PDF
為 Node.js 專案打造專屬管家進行開發流程整合及健康檢測
PDF
Web Performance Part 4 "Client-side performance"
PDF
JHipster Conf 2018 : Connect your JHipster apps to the world of APIs with Ope...
PDF
"Wix Serverless from inside", Mykola Borozdin
PPTX
Ci of js and apex using jasmine, phantom js and drone io df14
Евгений Жарков "React Native: Hurdle Race"
"How to Use Bazel to Manage Monorepos: The Grammarly Front-End Team’s Experie...
"13 ways to run web applications on the Internet" Andrii Shumada
為 Node.js 專案打造專屬管家進行開發流程整合及健康檢測
Web Performance Part 4 "Client-side performance"
JHipster Conf 2018 : Connect your JHipster apps to the world of APIs with Ope...
"Wix Serverless from inside", Mykola Borozdin
Ci of js and apex using jasmine, phantom js and drone io df14

What's hot (20)

PDF
JCConf 2015 workshop 動手玩 Java 專案建置工具
PPTX
Jenkins Job DSL plugin
PPT
Learn jobDSL for Jenkins
PPTX
Job DSL Plugin for Jenkins
PDF
Puppet Camp Paris 2015: Continuous Integration of Puppet Code (Intermediate)
PDF
Automated android testing using jenkins ci
PDF
Graphql usage
PDF
中華電信 教育訓練
PDF
Modern Infrastructure from Scratch with Puppet
PDF
Automation Testing
PDF
Виталий Редько "React + Redux: performance & scalability"
PDF
CI/CD Using Ansible and Jenkins for Infrastructure
PDF
JavaScript + Jenkins = Winning!
PPTX
Continuous Delivery With Selenium Grid And Docker
PPTX
Deploy Node.js application in Heroku using Eclipse
PDF
Rene Groeschke
ODP
Jenkins 101: Continuos Integration with Jenkins
PDF
JSDC 2015 - TDD 的開發哲學,以 Node.js 為例
PDF
Viktor Turskyi "Effective NodeJS Application Development"
PPTX
Supermondays: Jenkins CI lightning talk
JCConf 2015 workshop 動手玩 Java 專案建置工具
Jenkins Job DSL plugin
Learn jobDSL for Jenkins
Job DSL Plugin for Jenkins
Puppet Camp Paris 2015: Continuous Integration of Puppet Code (Intermediate)
Automated android testing using jenkins ci
Graphql usage
中華電信 教育訓練
Modern Infrastructure from Scratch with Puppet
Automation Testing
Виталий Редько "React + Redux: performance & scalability"
CI/CD Using Ansible and Jenkins for Infrastructure
JavaScript + Jenkins = Winning!
Continuous Delivery With Selenium Grid And Docker
Deploy Node.js application in Heroku using Eclipse
Rene Groeschke
Jenkins 101: Continuos Integration with Jenkins
JSDC 2015 - TDD 的開發哲學,以 Node.js 為例
Viktor Turskyi "Effective NodeJS Application Development"
Supermondays: Jenkins CI lightning talk
Ad

Similar to Володимир Дубенко "Node.js for desktop development (based on Electron library)" (20)

PDF
Cross-Platform Desktop Apps with Electron (CodeStock Edition)
PDF
Electron
PPTX
Electron - cross platform desktop applications made easy
PDF
PPTX
Cross-platform Desktop Apps development using HTML, CSS, JS with Electron
PDF
Cross-Platform Desktop Apps with Electron
PDF
Building Cross Platform Apps with Electron
PPTX
SubmitJS: Developing desktop applications with Electron. Mykyta Semenistyi
PDF
PDF
An overview of the architecture of electron.js
PDF
Building desktop applications for fun with electron
PDF
Electron presentation
PPTX
Cross-Platform Desktop Apps with Electron
PDF
Electron JS | Build cross-platform desktop applications with web technologies
PDF
PPTX
Learn Electron for Web Developers
PPTX
Building desktop apps in java script with Electron
PDF
Electron: Linux, Windows or Macos?
PDF
Electron Firenze 2020: Linux, Windows o MacOS?
PDF
Cross-Platform Desktop Apps with Electron (JSConf UY)
Cross-Platform Desktop Apps with Electron (CodeStock Edition)
Electron
Electron - cross platform desktop applications made easy
Cross-platform Desktop Apps development using HTML, CSS, JS with Electron
Cross-Platform Desktop Apps with Electron
Building Cross Platform Apps with Electron
SubmitJS: Developing desktop applications with Electron. Mykyta Semenistyi
An overview of the architecture of electron.js
Building desktop applications for fun with electron
Electron presentation
Cross-Platform Desktop Apps with Electron
Electron JS | Build cross-platform desktop applications with web technologies
Learn Electron for Web Developers
Building desktop apps in java script with Electron
Electron: Linux, Windows or Macos?
Electron Firenze 2020: Linux, Windows o MacOS?
Cross-Platform Desktop Apps with Electron (JSConf UY)
Ad

More from Fwdays (20)

PDF
"Mastering UI Complexity: State Machines and Reactive Patterns at Grammarly",...
PDF
"Effect, Fiber & Schema: tactical and technical characteristics of Effect.ts"...
PPTX
"Computer Use Agents: From SFT to Classic RL", Maksym Shamrai
PPTX
"Як ми переписали Сільпо на Angular", Євген Русаков
PDF
"AI Transformation: Directions and Challenges", Pavlo Shaternik
PDF
"Validation and Observability of AI Agents", Oleksandr Denisyuk
PPTX
"Autonomy of LLM Agents: Current State and Future Prospects", Oles` Petriv
PDF
"Beyond English: Navigating the Challenges of Building a Ukrainian-language R...
PPTX
"Co-Authoring with a Machine: What I Learned from Writing a Book on Generativ...
PPTX
"Human-AI Collaboration Models for Better Decisions, Faster Workflows, and Cr...
PDF
"AI is already here. What will happen to your team (and your role) tomorrow?"...
PPTX
"Is it worth investing in AI in 2025?", Alexander Sharko
PDF
''Taming Explosive Growth: Building Resilience in a Hyper-Scaled Financial Pl...
PDF
"Scaling in space and time with Temporal", Andriy Lupa.pdf
PDF
"Database isolation: how we deal with hundreds of direct connections to the d...
PDF
"Scaling in space and time with Temporal", Andriy Lupa .pdf
PPTX
"Provisioning via DOT-Chain: from catering to drone marketplaces", Volodymyr ...
PPTX
" Observability with Elasticsearch: Best Practices for High-Load Platform", A...
PPTX
"How to survive Black Friday: preparing e-commerce for a peak season", Yurii ...
PPTX
"Istio Ambient Mesh in production: our way from Sidecar to Sidecar-less",Hlib...
"Mastering UI Complexity: State Machines and Reactive Patterns at Grammarly",...
"Effect, Fiber & Schema: tactical and technical characteristics of Effect.ts"...
"Computer Use Agents: From SFT to Classic RL", Maksym Shamrai
"Як ми переписали Сільпо на Angular", Євген Русаков
"AI Transformation: Directions and Challenges", Pavlo Shaternik
"Validation and Observability of AI Agents", Oleksandr Denisyuk
"Autonomy of LLM Agents: Current State and Future Prospects", Oles` Petriv
"Beyond English: Navigating the Challenges of Building a Ukrainian-language R...
"Co-Authoring with a Machine: What I Learned from Writing a Book on Generativ...
"Human-AI Collaboration Models for Better Decisions, Faster Workflows, and Cr...
"AI is already here. What will happen to your team (and your role) tomorrow?"...
"Is it worth investing in AI in 2025?", Alexander Sharko
''Taming Explosive Growth: Building Resilience in a Hyper-Scaled Financial Pl...
"Scaling in space and time with Temporal", Andriy Lupa.pdf
"Database isolation: how we deal with hundreds of direct connections to the d...
"Scaling in space and time with Temporal", Andriy Lupa .pdf
"Provisioning via DOT-Chain: from catering to drone marketplaces", Volodymyr ...
" Observability with Elasticsearch: Best Practices for High-Load Platform", A...
"How to survive Black Friday: preparing e-commerce for a peak season", Yurii ...
"Istio Ambient Mesh in production: our way from Sidecar to Sidecar-less",Hlib...

Recently uploaded (20)

PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
Reach Out and Touch Someone: Haptics and Empathic Computing
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PDF
Dropbox Q2 2025 Financial Results & Investor Presentation
PDF
Network Security Unit 5.pdf for BCA BBA.
PPTX
Cloud computing and distributed systems.
PDF
The Rise and Fall of 3GPP – Time for a Sabbatical?
PDF
cuic standard and advanced reporting.pdf
PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
PDF
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
PDF
MIND Revenue Release Quarter 2 2025 Press Release
PDF
Review of recent advances in non-invasive hemoglobin estimation
PDF
Encapsulation theory and applications.pdf
PDF
Mobile App Security Testing_ A Comprehensive Guide.pdf
PDF
Approach and Philosophy of On baking technology
PDF
Chapter 3 Spatial Domain Image Processing.pdf
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PPTX
MYSQL Presentation for SQL database connectivity
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
Reach Out and Touch Someone: Haptics and Empathic Computing
Agricultural_Statistics_at_a_Glance_2022_0.pdf
Dropbox Q2 2025 Financial Results & Investor Presentation
Network Security Unit 5.pdf for BCA BBA.
Cloud computing and distributed systems.
The Rise and Fall of 3GPP – Time for a Sabbatical?
cuic standard and advanced reporting.pdf
Diabetes mellitus diagnosis method based random forest with bat algorithm
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
MIND Revenue Release Quarter 2 2025 Press Release
Review of recent advances in non-invasive hemoglobin estimation
Encapsulation theory and applications.pdf
Mobile App Security Testing_ A Comprehensive Guide.pdf
Approach and Philosophy of On baking technology
Chapter 3 Spatial Domain Image Processing.pdf
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
Digital-Transformation-Roadmap-for-Companies.pptx
MYSQL Presentation for SQL database connectivity

Володимир Дубенко "Node.js for desktop development (based on Electron library)"

Editor's Notes

  • #3: Спочатку трохи про себе
  • #5: Чому я обрав Електрон для розробки?
  • #6: Нам потрібно було створити продукт для автоматизації 3D друку. Багато розповісти не можу, тільки скажу, що це виробництво окулярів для одного відомого бренда
  • #7: Мені потрібно було вибрати на чому писати новий продукт
  • #8: Було сильне бажання поексперементувати з технологіями і, можливо, обрати для компанії альтернативу для Майкрософт технологій
  • #9: Виникла ідея, що можна спробувати створити продукт на веб технологіях
  • #10: Основні варіанти: Electron – в минулому Atom-shell, створена і підтримується GitHub командою NW.js – в минулому node-webkit – створена Intel командою Архітектура цих бібліотек різна, але обидва вони мають багато інструментів, велику ком’юніті і однаково можуть бути використані для ваших проектів Мій вибір пав на Електрон через більшу ком’юніті,
  • #11: Також при виборі імпонувало те, що вже багато смачних речей написано на Електроні
  • #12: Також треба сказати, що за допомогою Електрона можна створити кросс-платформ продукт і з єдиним code base запускати продукт на Wim, Mac, Linux
  • #13: На даний момент Електрон має чималу ком’юніті Можна знайти на гітхабі велику кількість репозиторіїв і NPM пакетів, пов’язаних з Електроном
  • #14: Щоб зрозуміти чи Електрон підходить нашим цілям ми вирішили почати з неличкого Proof of Concept
  • #15: Для створення ходячого костяка нам допоможе electron-forge – це CLI створений електрон командою
  • #16: Після запуску ми побачимо ось такий результат Електрон використовує Хроміум для рендерингу інтерфейсу
  • #17: Давайте подивимось на код створеної аппки У нас є стандартна структура Node.js аплікухи – package.json файл із залежностями і конфігурацією нашої аппки
  • #18: Давайте подивимось на index.js файл. В ньому вся логіка по керування нашим основним процесом app – class for app lifecycle BrowserWindow – створення і керування вікнами
  • #19: Електрон аппка складається з: Основного процесу, який створює і керує вікнами Кожне вікно запускається в окремому ізольованому процесі, яке хоститься в Хроміумі V8 ES2017
  • #20: Далі нам треба було створити інтерфейс Враховуючи як Електрон створює і працює з вікнами ми вирішили, що найпростішим рішенням було б – створення Single Page Application
  • #21: Ось як виглядає інтерфейс нашого продукту Давайте подивимось як ми зробили
  • #22: Ми вибирали між наступними фреймворками. Для всіх фреймоворків можна знайти Quick-start гайди і Boiler plates на гітхабі, а також велику кількість блог постів. Зупинились ми на Аурелії через простоту створення темплейтів сторінок і контролів
  • #23: Якщо хтось із вас не знайомий з Аурелією, то ось як виглядає теплейт view на Аурелії Як ви бачите – це звичайний HTML з атрибутами Аурелії
  • #24: 1. Нажаль electron-forge не мав теплейту для Аурелії, тому ми пішли іншим шляхом 2. … code 3. Цим шляхом можна конвертувати будь-який веб продукт (написаний чи на Аурелії, чи на будь-чому іншому) – на Електрон додаток
  • #25: Дизайн нашого продукту був побудований на Material Design Lite
  • #26: 1. UI Dev -> web mode За допомогою CLI Аурелії (au run --watch) після змін в коді, відбувався live reload сторінки
  • #27: Також при розробці інтерфейсу допомогли VS плагіни для Аурелії
  • #31: Як була організована комунікація між Node і Chromium процесами
  • #32: 1. Для комунікації між процесами ми обрали ipc-promise пакет. Це wrapper над вбудованим в Електрон пакетами ipcMain + ipcRenderer, який дозволяє використовувати promises як результат вашої функції Add packet + include into Au bundle 2. Main process: ipcPromise = EventEmitter – subscribing for named events 3. Renderer process - call
  • #33: Як була організована комунікація між App і Microservices
  • #34: 1. Для отримання даних від microservices ми організували наступну схему: Рендерер процес робить запит в основний процес, а той в свою чергу звертається до microservice І зворотнім чином дані ідуть назад 2. Ось приклад коду, який робить запит до microservice і повертає promise Цікавою особливістю роботи пакету ipc-promise є те, що promise не може бути rejected, інакше рендерер процес не отримає response Така схема була обрана для того, щоб не мати проблем з cross-damain викликами (CORS) Також можна звертатись до мікросервісів із рендерер процесу, тоді ви уникнете дублювання коду, але потрібно буде вирішити питання з cross-damain викликами
  • #36: Для тестування ми використовуємо дещо різні підходи для Main process і Renderer Process
  • #37: Для тестування main process -> jasmine test runner Для дебагу використовуємо VS Code
  • #38: Для Renderer process ми використовуємо тест раннер – Карму. Тест фреймворк – Jasmine Для дебагу використовуємо Chrome Як результат у нас немає інтеграційних тестів між двома процами
  • #41: Icon added, product name from package.json, ярлик на робочу столі – all with help of small configuration No configuration installer Size installer – 57 MB, Installed app – 262 MB
  • #43: Біль / Challenge – це інтеграція із WCF сервісом, який використовує тільки NTML аутентифікацію Ми перепробували з 4-5 Node.js різних пакетів із різними налаштуваннями ->
  • #44: В кінці запрацював солюшен із пакетом httpntlm for calls and xml2js for parsing results
  • #46: Generation: JSReport – in Electron App, in microservice, in Wim virtual machine on Azure, finally on Linux App service
  • #47: Printing: For saving time FoxitReader (via spawning process) Alternative – node-printer Node module, which is native and require recompilation
  • #48: Ще хочу поділитись декількома цікавими ідеями
  • #49: Ще одною цікавою комбінацією для вас може бути наступна пара Ionic – це веб фреймворк для побудови мобайл додатків. Він так само як Електрон дозволяє використовувати HTML, CSS, JS Електром, як ви вже знаєте дозволяє будувати десктоп додатки Якщо їх об’єднати, ви зможете робити на єдиному code base і кросс-платформенні десктоп і мобайл продукти
  • #50: Ця ліба для десктоп Node додатків. Вона дозволяє контролювати клавіатуру, мишку і читати монітор Вжє є багато створених додатків для запису дій користувача і їх повтору, або для sharing’у екрану
  • #52: electronjs.org – сайт електрона Awesome electron – репоситорій з усіма цікавими речами зібраними в одному місці – boilerplates, video, libraries Так що. Якщо ви закоренелий фронтендщик, але вас попросили зробити якийсь десктоп продукт, то ви тепер знаєте що є вихід із ситуації