node js periksa apakah dipanggil dari modul
if (require.main === module) {
console.log('called directly');
} else {
console.log('required as a module');
}
garzj
if (require.main === module) {
console.log('called directly');
} else {
console.log('required as a module');
}