4 ms·
One thing I've been playing around with is the idea of coupling ORM-style models with rules about how those models should be presented as a JSON-API. https://g
by AlexeyMK 15y ago
One thing I've been playing around with is the idea of coupling ORM-style models with rules about how those models should be presented as a JSON-API.
https://gist.github.com/1823921 https://gist.github.com/1823921
The approach breaks a lot of 'separation of concerns' rules between the view and the model, but for certain kinds of APIs (read-only, in particular) this may be fine. Would be interesting in feedback/seeing where similar projects have gone.