1
0 Comments

Your blog's 'front page' is now working

If you go to a blog, it'll show article previews - starting with the newest. This is based on the order articles are added to the database - oldest to newest (top/down). Then we reverse the array of articles to have the newest ones first.

It's taken a bit of time to get this page working. Previously, I wasn't storing article content in the database - it was in GitHub. Because of this, there didn't seem to be a good way to display articles on the front page of a blog.

Now, when you upload a new article to your repo, we parse the markdown, gather some data/content, and store a copy in our database.

Slightly off-topic:

This also saves API requests to GitHub. As an authenticated GitHub app, we are allowed 5,000 requests per hour per repo.

Since a copy of the content is now in the database, I can begin refactoring code to pull individual article requests from there too. Right now, when you go to an article (not the main blog page), it pulls the data from the cache if it can, then grabs it from GitHub.

Once this refactoring is complete, the only time we should be making a request to GitHub for content is when you add or update an article.

Trending on Indie Hackers
After 10M+ Views, 13k+ Upvotes: The Reddit Strategy That Worked for Me! 42 comments Getting first 908 Paid Signups by Spending $353 ONLY. 24 comments I talked to 8 SaaS founders, these are the most common SaaS tools they use 20 comments What are your cold outreach conversion rates? Top 3 Metrics And Benchmarks To Track 19 comments Hero Section Copywriting Framework that Converts 3x 12 comments Join our AI video tool demo, get a cool video back! 12 comments