Home logo

My Journey of Creating Desktop App in JavaScript

GX Anshu | Sat Jul 01 2023

Recently, I’ve been working on developing a software application called QuickPDF that aims to assist designers in creating newspaper layouts more efficiently.

The initial inspiration for this project came when I visited my father’s friend’s office. He owns a newspaper company and had requested a newspaper design from a designer, but due to an overwhelming workload, the designer couldn’t fulfill the request on time. It turned out that the designer had taken on multiple projects from different clients to increase their earnings. However, designing PDFs was time-consuming, leading to delays. This got me thinking: why not create a software solution that could streamline the process of building newspaper PDFs?

Excited by the idea, I began brainstorming software features that could effectively reduce the time required for creating newspaper layouts. Unfortunately, due to some personal issues, I initially abandoned the project, not taking it as seriously as I should have. However, after the passing of my mother and with a renewed sense of determination, I made the decision to dive back into the project.

As a solo developer without a team or assistance, I contemplated creating a web application to achieve the desired functionality. However, concerns regarding server costs and other expenses associated with running the product made me reconsider. That’s when I had a breakthrough: why not develop a desktop application instead? However, I faced a challenge—I lacked the necessary expertise to create a native desktop application using languages like C or C++, or even frameworks like GTK in C++ or Qt in Python. Considering my familiarity with JavaScript, I opted to develop the application using this language.

Creating a desktop app with JavaScript presented its own set of challenges. To run JavaScript on a computer, Node.js must be installed. In other words, in order for others to run my application, I would need to package it with Node.js. Additionally, rendering the user interface (UI) as a webpage required incorporating a browser into the application. Initially, Electron.js seemed like a viable solution. However, I was concerned about potential performance issues associated with Electron.js.

In my search for alternative tools, I stumbled upon Tauri, a desktop app creator that utilizes JavaScript but handles the backend work using the Rust programming language instead of relying on Node.js. Moreover, Tauri leverages the native browser available in the user’s operating system to render content, eliminating the need to include a separate browser within the application.

Excited by this discovery, I commenced work on the project. However, I encountered an issue with drag and drop functionality in Tauri JS. I raised an issue on the Tauri GitHub repository, which was acknowledged as a bug. Unfortunately, I didn’t receive a solution for three days, prompting me to consider developing the application using Electron.js instead.