You can create (and find) many types of programs. We can generally classify them into 2 macro groups:

  1. programs that have a Graphical User Interface (GUI)
  2. programs that have a Command Line Interface (CLI)

The difference between the two is significant, and it’s the same between DOS and Windows, if you are familiar with those 2 environments.

Or the same between the Linux you run on a server, and the Gnome or KDE based Linux you run on your desktop computer.

GUI applications have an interface you interact with using the mouse, and you can clearly see it on the screen, typically inside a window, along with other GUI applications. Many GUI applications run at the same time.

A CLI applications is accessed from a terminal, a text based interface which only allows you to run one active application at a time.

Generally speaking, CLI applications are great for apps for pro users, that know how to access the terminal inside their system (it’s available on any kind of computer), and how to use any CLI app. They know how to find the help for the app, and are generally tech savvy.

A CLI application is the most flexible kind of application because the UI does not need to be filled with options - options are typed by the user if needed. They are best suited for one-time tasks. Or even long running tasks, provided you can run multiple terminal windows.

Think create-react-app, Vim, the C compiler, and more.

One special kind of CLI apps are backend applications that do not interface with the user on the system, but accept interactions across the network. In this case, the CLI is used to start (and stop) the application. Or to provide a way to instruct the system to run the application as a daemon (a long running process).

GUI applications on the other hand need a way to visually offer all the available options on the screen. They are best suited to provide rich interactions for mouse based inputs. Think Microsoft Word or Google Earth or the Chrome browser.

In JavaScript you will generally create both kind of applications. GUI apps using React, Vue, or any other framework that will run inside the browser (the actual GUI app, actually).

And CLI apps using Node.js, to provide services through network connections.


Go to the next module