Hacker News new | past | comments | ask | show | jobs | submit login

Ugh. After living in frontend land (native mobile and react) I'm really not looking forward to going back to Django.

It feels so irrelevant in the world of backend-as-a-service and GraphQL.

...Please forgive my cynicism. I am looking for a reason to like this. Maybe I should just move on.




I had the opposite experience. Every time I see a JS project trying to do a bit of custom registration and some serious DB design, it's such a pain. The JS stack is great for pretty stuff, but the basics require so much boiler plate.


That's fair.

What got me thinking about these ideas were cases where having a distributed frontend felt overengineered. If you have problems where GraphQL makes sense, this would be a step in the wrong direction.


To be honest, I'd use GraphQL at any scale. I've recently used it in programming challenges for job interviews, and I've used it in production for about 18 months. It's such a good conceptual fit for front-end, that it now feels strange to work any other way.


Looks to be an alternative to the traditional "rest api".

Would anyone care to comment on the productivity benefits of one or the other?


It's more like an enhancement of the traditional backend-for-frontend (BFFs) pattern, enabling ad-hoc endpoints (based on queries) rather than static ones.

The main productivity benefit comes from the fact that the query language is a very good fit for the component model. Each component can declare its data dependencies in the form of query fragments, and these get composed into a single query for the entire UI. It means every time you use a component, you can be sure that you'll have the data you need.

I should add that none of this is a unique capability of GraphQL, I know people who've built similar component-data binding with JSON-API, but it's the full package that's compelling. The query language is lovely to work with. You can build GraphQL schemas around the needs of clients, allowing you to hide any weird data modelling or service boundaries you may have in your platform. As an API designer, as well as a front-end developer, I love it.





Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: