• thingsiplay@beehaw.org
    link
    fedilink
    arrow-up
    4
    ·
    18 hours ago

    Netscape asked Brendan Eich to develop a scripting language that looks like Java, but be object oriented rather than class based.

    I don’t understand this part. Isn’t object oriented also class based?? I mean that’s the entire reason why classes exist, to create objects. Isn’t it? How is this separated here?

    • anton@lemmy.blahaj.zone
      link
      fedilink
      arrow-up
      3
      ·
      17 hours ago

      To my understanding, the original meaning of object oriented is more similar to what we call the actor model today.

      In reference to the modern understanding of OO, js uses prototypal inheritance, which some consider closer to the original vision.

    • vermaterc@lemmy.ml
      link
      fedilink
      arrow-up
      2
      ·
      17 hours ago

      Object oriented languages can be either class based or prototype based. Java is class based, JS was back then prototype based

      • thingsiplay@beehaw.org
        link
        fedilink
        arrow-up
        1
        ·
        17 hours ago

        Thanks, I see. I’ll research and learn more about the differences. Thought this was an writing error and didn’t research yet.

        • vermaterc@lemmy.ml
          link
          fedilink
          arrow-up
          1
          ·
          16 hours ago

          I mean: it is a writing error, because you can’t compare “class based” to OOP, since they are just different things, but this is what is suspect was the case ;)