TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Show HN: Top 10 Newest HackerNews Stories (Phoenix/LiveView)

5 点作者 gstipi大约 5 年前
HNLive is a small Elixir&#x2F;Phoenix&#x2F;LiveView web app showing the top 10 (by score or number of comments) newest HackerNews stories in &quot;real time&quot; (i.e. as quickly as updates become available via the HackerNews API).<p>You should find the app running on https:&#x2F;&#x2F;hntop10.gigalixirapp.com - please note that this is running on the free tier with limited memory and resources.<p>GitHub: https:&#x2F;&#x2F;github.com&#x2F;gstipi&#x2F;hnlive<p>The motivation for building HNLive was twofold:<p>1. I had read and heard many good things about Elixir, Phoenix and LiveView, and after watching Chris McCord`s demo &quot;Build a real-time Twitter clone in 15 minutes with LiveView and Phoenix 1.5&quot; on YouTube, I finally said to myself: &quot;That looks awesome, time to learn Elixir and Phoenix!&quot; HNLive is the app I built over the last couple of days while on this learning journey.<p>2. I love browsing HackerNews, but for me the selection of stories on the front page, the &quot;newest&quot; page and the &quot;best&quot; page is not ideal if I want to see at a glance which new stories (say, submitted over the course of the last 12 hours) have received the most upvotes or are discussed particularly controversially (as judged by the number of comments). HNLive attempts to address this using data from the HackerNews API to provide the top 10 submissions, sorted by score or number of comments, taking into account only the last 500 submissions. I also wanted to see updates to the top 10 (and scores and number of comments) in real time, which was made easy by using LiveView.

1 comment

gstipi大约 5 年前
Link to the app on Gigalixir: <a href="https:&#x2F;&#x2F;hntop10.gigalixirapp.com" rel="nofollow">https:&#x2F;&#x2F;hntop10.gigalixirapp.com</a> (since URLs do not become links in the text field of a submission)