Book description
A project-based guide to help you create, package, and deploy desktop applications on multiple platforms using modern JavaScript frameworks
Key Features
- Use your web development skills with JavaScript and Node.js to build desktop applications for macOS and Windows
- Develop desktop versions of popular mobile applications that are similar to Slack, Spotify, and more
- Design desktop apps with automatic updates and real-time analytics capabilities
Book Description
The Electron framework allows you to use modern web technologies to build applications that share the same code across all operating systems and platforms. This also helps designers to easily transition from the web to the desktop. Electron Projects guides you through building cross-platform Electron apps with modern web technologies and JavaScript frameworks such as Angular, React.js, and Vue.js.
You'll explore the process of configuring modern JavaScript frameworks and UI libraries, real-time analytics and automatic updates, and interactions with the operating system. You'll get hands-on with building a basic Electron app, before moving on to implement a Markdown Editor. In addition to this, you'll be able to experiment with major JavaScript frameworks such as Angular and Vue.js, discovering ways to integrate them with Electron apps for building cross-platform desktop apps. Later, you'll learn to build a screenshot snipping tool, a mini-game, and a music player, while also gaining insights into analytics, bug tracking, and licensing. You'll then get to grips with building a chat app, an eBook generator and finally a simple digital wallet app.
By the end of this book, you'll have experience in building a variety of projects and project templates that will help you to apply your knowledge when creating your own cross-platform applications.
What you will learn
- Initialize Node.js, Node Package Manager (NPM), and JavaScript to set up your app
- Integrate Phaser with Electron to build a simple 2D game
- Improve app quality by adding an error tracking system and crash reports
- Implement group chat features and event handling capabilities using Firebase
- Integrate a WordPress-like rich-text editor into your app
- Build Electron applications using a single codebase
Who this book is for
This book is for JavaScript developers who want to explore the Electron framework for building desktop apps. Working knowledge of modern frontend JavaScript frameworks and Node.js is assumed. No prior knowledge of desktop development is required.
Table of contents
- Title Page
- Copyright and Credits
- Dedication
- About Packt
- Contributors
- Preface
- Building Your First Electron Application
-
Building a Markdown Editor
- Technical requirements
- Configuring a new project
- Integrating the editor component
- Fitting the screen size
-
Integrating the application menu
- Creating a custom menu item
- Defining menu item roles
- Providing menu separators
- Supporting keyboard accelerators
- Supporting platform-specific menus
- Configuring the application name in the menu
- Hiding menu items
- Sending messages between processes
- Saving files to a local system
- Loading files from a local system
- Creating a file menu
- Adding drag and drop support
- Supporting automatic updates
- Changing the title of the application
- Summary
-
Integrating with Angular, React, and Vue
- Technical requirements
- Building an Electron application with Angular
- Building an Electron application with React
- Building an Electron application with Vue.js
- Summary
-
Building a Screenshot Snipping Tool
- Technical requirements
- Preparing the project
- Configuring frameless windows
- Transparent windows
- Making application windows draggable
- Adding a snip toolbar button
- Using the desktopCapturer API
- Calculating the primary display size
- Generating and saving a thumbnail image
- Resizing and cropping the image
- Testing the application's behavior
- Integrating with the system tray
- Hiding the main application window on startup
- Registering global keyboard shortcuts
- Summary
- Making a 2D Game
- Building a Music Player
-
Analytics, Bug Tracking, and Licensing
- Technical requirements
- Understanding analytics and tracking
- Creating your own solution or using an existing service
- Using Nucleus for Electron applications
- Creating a new Nucleus account
- Creating a new project with tracking support
- Installing the Nucleus Electron library
- Inspecting real-time analytics data
- Disabling tracking per user request
- Verifying real-time user statistics
- Supporting offline mode
- Handling application updates
- Loading global server settings
- License checking and policies
- Summary
-
Building a Group Chat Application with Firebase
- Technical requirements
- Creating an Angular project
- Creating a Firebase account
- Creating a Firebase application
- Configuring Angular Material components
- Building a login dialog
- Connecting the login dialog to Firebase Authentication
- Configuring the Realtime Database
- Rendering the group list
- Implementing the group messages page
- Displaying group messages
- Sending group messages
- Verifying the Electron Shell
- Summary
- Building an eBook Editor and Generator
-
Building a Digital Wallet for Desktops
- Technical requirements
- Generating the project scaffold with React
- Integrating the Ant Design library
- Setting up a personal Ethereum blockchain
- Configuring the Ethereum JavaScript API
- Displaying Ethereum Node information
- Integrating with the application menu
- Rendering a list of accounts
- Showing our account balance
- Transferring Ether to another account
- Packaging the application for distribution
- Summary
- Other Books You May Enjoy
Product information
- Title: Electron Projects
- Author(s):
- Release date: November 2019
- Publisher(s): Packt Publishing
- ISBN: 9781838552206
You might also like
book
Electron in Action
Electron in Action guides you, step-by-step, as you learn to build cross-platform desktop applications that run …
book
Angular Projects - Second Edition
PUBLISHER'S NOTE: An updated 2023 edition, compatible with Angular 16, is now available. Key Features Explore …
book
React Projects - Second Edition
Learn how to develop real-world applications of varying complexity for the web, mobile, and VR devices …
book
React Projects
Build cross-platform applications of varying complexity for the web, mobile, and VR devices using React tooling …