Re:Rebuilding the Shopify Admin: Deleting 28k lines of JavaS...
by matthewmacleod on Wednesday October 29, 2014 @03:02AM
(#8525912)
I don't know that what you've identified there is actually a problem in practice – I'd wager that in a system like Shopify's admin, the client and server are inherently coupled regardless of what architecture you choose. Trying to abstract to a client-side app and JSON API in these situations often results in more complexity for few benefits.
[ Parent
| on HN ]
Re:Rebuilding the Shopify Admin: Deleting 28k lines of JavaS...
by wvanbergen on Wednesday October 29, 2014 @09:13AM
(#8526951)
This. We ended up creating models for the exact same stuff in both Ruby and JS. Lots of code duplication, and losing client-side performance due to deserializing JSON all the time.
Re:Rebuilding the Shopify Admin: Deleting 28k lines of JavaS...
by Joeri on Wednesday October 29, 2014 @03:19AM
(#8525944)
If you have multiple front ends on top of a shared backend, like a desktop and mobile UI, as well as a bunch of third party integrations, then it makes a lot of sense to build the API first. The thing is that it requires three different use cases before you can make an API generic enough to cover the majority of the needs, and that makes it difficult to build the API first and UI later. I believe in the approach, but it's not the right way to go for everybody.