Quiz on Deep Dive into Metaprogramming

Test your knowledge of metaprogramming complexities.

1

Given the handler

const handler = {
  get: function(target, propertyName, receiver) {}
};

and the following code to use as a proxy:

const sample = {};
const proxy = new Proxy(sample, handler); const value = proxy.foo;

What does the parameter target, in the get trap, refer to during the execution of the last line of this code?

A)

sample

B)

foo

C)

proxy

Question 1 of 50 attempted

Get hands-on with 1400+ tech skills courses.