Hey, so, uh... all you need to clone HN is Postgres and some HTML/CSS and a smidgen of JavaScript. Good God, must we pull in the entire JavaScript ecosystem for a simple forum now?
This is why the JS community is so fucked. They take what should be a simple website and needlessly complicate it by (poorly) reimplementing what web browsers can already do.
Hacker News Clone Using GraphQL and React
61–70 of 187 posts
Re: Hacker News Clone Using GraphQL and React
#62Hey, so, uh... all you need to clone HN is Postgres and some HTML/CSS and a smidgen of JavaScript. Good God, must we pull in the entire JavaScript ecosystem for a simple forum now?
It's called a 'reference architecture'. It's intended to be used as a teaching tool and learning tool for a stack that has tremendous benefits for applications more complex than HN. Since everyone is familiar with HN on HN, they can look at that code and understand how it fits in with the big picture without having to learn a new app PLUS a new architecture. [1] https://en.wikipedia.org/wiki/Reference_architecture
Re: Hacker News Clone Using GraphQL and React
#63The latency of clicking on the "comments" link is greater than actual HN (about 0.9s) for an example I tried, of which about half is spent in the POST network request, another half in JavaScript and layout/rendering/painting. For actual HN the whole process is well below 0.5s. Seems like with more comments it is much slower.
Re: Hacker News Clone Using GraphQL and React
#64Re: Hacker News Clone Using GraphQL and React
#65What happens when two components used in two totally different areas of a single page need common data? Relying on a cache feels like a hack.
I really love React but really dislike the way I see it being used these days. I think of it as a polyfill for a UI component that should be stateless and free of side effects. Not an end to end controller/fetcher/renderer.
Re: Hacker News Clone Using GraphQL and React
#66Willing to pay for such a theme.
Re: Hacker News Clone Using GraphQL and React
#67I really dislike the tendency to couple graphql queries with components. Is this idiomatic? If you are comfortable with side effects in your presentation layer i’d much rather manage data at a higher level and have a component request the data it needs from that. As opposed to actually making HTTP requests. What happens when two components used in two totally different areas of a single page need common data? Relying…
Re: Hacker News Clone Using GraphQL and React
#68Fantastic resource! The key point of this is it provides working example code to start a project from. Everything is MIT Licensed so that means you get to download it and just start hacking.
I would love to see some accompanying video tutorials!
Of course people are also free to post their own examples using their own favorite technologies. I would love for 'HN Clone' to become a benchmarking standard for comparing stacks. It seems like a bit too much work for such a purpose, but that's the point! :-)
I don't think authentication is actually working in the demo, by the way. Don't be tempted to actually log in to your own account! But I tried creating a new account and it failed.
Re: Hacker News Clone Using GraphQL and React
#69Re: Hacker News Clone Using GraphQL and React
#70The real link: http://www.hnclone.win/ Fantastic resource! The key point of this is it provides working example code to start a project from. Everything is MIT Licensed so that means you get to download it and just start hacking. I would love to see some accompanying video tutorials! Of course people are also free to post their own examples using their own favorite technologies. I would love for 'HN Clone' to become…
Besides GraphQL you mean