4 ms·
I am also a Rails dev, but one feature I think Django really got right that is head and shoulders above Rails are Form Objects (https://docs.djangoproject.com/e
by dasil003 11y ago
I am also a Rails dev, but one feature I think Django really got right that is head and shoulders above Rails are Form Objects (https://docs.djangoproject.com/en/1.9/topics/forms/ https://docs.djangoproject.com/en/1.9/topics/forms/). Rails' attr_accessible stuff and even strong_parameters really pales in comparison.
- ralmidani 11y agoI do rendering on the client-side, so do not use Django's Forms. But there are ModelForms which integrate seamlessly with your model because it is the definitive representation of a real-world object. Similarly, Django Rest Framework has ModelSerializers and ModelViewSets which give you a lot of free functionality out-of-the-box precisely because Django's Model layer was designed with DRY in mind.