exporting a class
Exporting a Class in JavaScript
Exporting a class is an essential feature of object-oriented programming in JavaScript. It allows you to reuse the class in different parts of your application or share it with other developers.
Using module.exports
The most common way to export a class in JavaScript is