JavaScript เป็นภาษา pass by value แต่สำหรับออบเจ็กต์ ค่าคือ reference ของมัน ดังนั้นเช่น ถ้าส่ง int ไปฟังก์ชันเป็น parameter และเพิ่มค่าในฟังก์ชัน ค่าใน callers context จะไม่เปลี่ยนตัวอย่างlet i = 0; function increment(x) { x = x + 1 console.log(x) } increment(i) console.lo