resgateio / resgate

A Realtime API Gateway used with NATS to build REST, real time, and RPC APIs, where all your clients are synchronized seamlessly.
https://resgate.io
MIT License
685 stars 67 forks source link

Delete property on change event #1

Closed jirenius closed 6 years ago

jirenius commented 6 years ago

Issue

RES protocol currently provides no way of deleting a model property once it is set.

Suggested solution

A special object, eg. {"action":"delete"}, could indicate deletion.

{
    "foo": "New or changed value",
    "bar": {"action":"delete"}
}
jirenius commented 6 years ago

Fixed in pull request https://github.com/jirenius/resgate/pull/9