You are viewing a single comment's thread from:

RE: Objects in JavaScript

in Programming & Dev2 years ago

TIL that you can delete properties from objects... I have no idea why anyone would want to do that, but uh, yeah okay, so you can do that...

As someone who came from other languages, JavaScript objects always felt really weird... they are like dictionaries (hashmaps...) but at the same time is not exactly good for tasks that you usually will let a dictionary do (and hence JavaScript now has a map type for that). It's also insanely flexible, so without much care and documentation it'll accidentally turn into a scary blob that no one knows what it is until they console.log() it out in the console (it's part of my job...). Still a very important and fun part of JavaScript though.