Overwhelmed with too many posts in an unending river of content, I decided to try and build an alternative way to navigate Hacker News.
I was recently interviewed for the Indie Hackers Podcast, host Courtland Allen asked lots of great questions about Pod Hunt.
While discussing the daily leaderboard that Pod Hunt implements, borrowed from Product Hunt, I realized this was something that would improve my experience on other websites, especially a site like Hacker News.
I'm a big fan of Hacker News, but always find visiting the homepage a bit overwhelming. When I was more active on Hacker News I used the alternative interface provided by hckr news.
This gets pretty close to what I wanted but not exactly. So in typical maker fashion, I wanted to see if it was was possible to build a daily leaderboard style display for Hacker News, but I'm focusing on Pod Hunt at the moment, so it had to be done quickly!
Getting the Data
YCombinator that runs Hacker News is pretty open with access to Hacker News.
At one point the source code of the site itself was available, but I can't find an up-to-date copy anywhere at the moment. The data however is available in a couple of different ways.
Firebase powers a REST based API that provides information in near realtime.
Algolia collects the information from the Firebase and powers an API centered around search.
After reviewing the two APIs I decided that to use the Firebase API.
Building the data store
I found a PHP library for using the Firebase API, although it hasn't changed in a couple years, I don't think the underlying API has changed either, so I decided to give it a try.
In about an hour I was able to build a very simple app that queried the API, saved the posts to a local database for performance reasons, and then listed the submissions segmented by date.
UI / UX
Since Hacker News get so many submissions each day (over 100 is normal) I wanted to make the list easier to consume. I decided to display the top 10 episodes per day and then allow the user to expand the list to see the rest.
I spent a little time making the site look nice, and I was close to done. I did add a quick search form, that just directs the query back to the Algolia powered search.
Getting to Production
I decided on the name Hacker News Day, registered the domain and got things setup and deployed on an existing Digital Ocean server.
All in I spent about 3 hours on the project, and I've been using it regularly ever since, I hope you do too!
The content is refreshed from the API every 5 minutes, and currently the site only displays the last 6 days, but I might add a way to scroll back further.