export default function throwOnUndefinedProperty(obj) {
  var handler = {
    get: function get(target, property) {
      if (property === "__isProxy") {
        return true;
      }

      if (property in target) {
        return target[property];
      }

      throw new Error("Property '".concat(property, "' is not defined"));
    }
  };
  return new Proxy(obj, handler);
}