Git Product home page Git Product logo

Comments (3)

skatcat31 avatar skatcat31 commented on May 23, 2024 1

There's two ways we can take this:

  1. Assuming Objects are POJS(Plain Old Javascript) which means no Getter or Setters as then it becomes an instance of a custom type with no prototype
  2. Include information about proxies(Getters, Setters, actual Proxies) and custom types and attempt to support them

I'm more for version 1 since program modification of an Object needs to be documented and should be known by the developer. At that point it's no longer an Object but a custom type as a Developer should always know what is happening in their code(after all they're the ones who maintain it)

This could open a corollary question about "How do you clone an Object with Proxy Methods?" which requires some CS knowledge on what a Proxy Method is, and thankfully can be marked Expert since this is some knowledge that most people can get by without ever actually needing, but in certain situations can be extremely useful.

from 30-seconds-of-interviews.

skatcat31 avatar skatcat31 commented on May 23, 2024

Since there haven't been any other opinions expressed in the past week we'll be going with 'assume POJS' and issuing a won't fix tag.

from 30-seconds-of-interviews.

skatcat31 avatar skatcat31 commented on May 23, 2024

Reasoning:

Custom types without prototypes or Class instantiation are a designer/developer choice choice. It is always up to the developer to be aware of what they are doing in their code at any one time. Because of this we have decided to not support proxy methods in this snippet as it is considered "developer implemented" behavior.

from 30-seconds-of-interviews.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.