Re: [webpayments] PROPOSAL: The PaymentRequest object will not have code attached to it. It will be a pure data object. (#64)

I don't think this is a helpful way to frame things.  If we have use cases that need state, then we need to manage the state.

Even in a mostly-stateless API like Fetch, you will notice that the request *does* have methods.  And even then, let's not forget that in JS, attributes can be backed by code:

```
let obj = { get foo() { return Math.random(); } };
console.log(obj.foo);
console.log(obj.foo);
```

So the distinction you're talking about is not really well-defined.  You could perhaps require that things work for the "POJSO" case, but trying to rule out code in the object is quixotic.

---
Reply to this email directly or view it on GitHub:
https://github.com/w3c/webpayments/issues/64#issuecomment-174195588

Received on Saturday, 23 January 2016 15:52:23 UTC