🧐 Spiders & Bots love SSR

Bots and crawlers have a thing against single page apps. This is where SSR comes in and why.

Server-side rendering has always been React's painful little side thorn. In part, it's because React's existence aims to do one thing and do it well - render stuff quickly and efficiently without giving developers too much of a headache.

While the ideas behind React is great, it also proved to be its Achilles heel - especially when it comes to SEO.

Bots and crawlers have a thing against single page apps.

It's fine if you're just using React to build the app portion.

Things get funky once you start incorporating headless CMS into the mix. Why? Because bugs and bots are made to read HTML - not JavaScript.

But it's 2022 - surely, Google and co. would have figured out how to properly crawl JavaScript by now.

In reality, Google crawlers do render JavaScript to extract links from it. The issue caused by JavaScript is in the lag time between crawling and indexing.

Crawling is the discovery phase whilst indexing is the act of storing and organizing where things rank in the grand scheme of page rankings. When a bot is crawling through a JavaScript SPA, all the internal links are not part of the HTML - so the crawler needs to wait.

Waiting for anything is the bane of efficiency. This is why SPAs struggle with SEO in general because while crawlers are generally patient, there is a thing called a 'crawl budget'. At some point, your crawler is going to give up on your SPA and move on to something else.

This is why there is a resurgence in discussions about SSR - or server-side rendering.

What is server-side rendering?

Think your old school, processed on the server and you get an actual HTML document back kind of set up. But it's not that black and white - and this article explains it quite well.

This 4-part history of the web series also maps out how we got to where we are now.

For those that just want to jump right into it, here's a list of SSR frameworks for JavaScript:


📌 What I'm reading

This week, I started reading Tools of Titans as I find myself getting bored of the usual flow of productivity and motivation content that's recycled ad-nauseam in my feed.

I've seen the title floating around for years but never picked it up until now.

The quick flip-through verdict is this: it's not your typical, feel-good productivity motivation content. It's raw, real, and to the point - summarized into bite-sized interview-esque recaps of people that's done and achieved something.

Overall, I'm liking it since it vibes well with my current state of jumping around content to keep learning and entertained.

Quote of the week

💡
Losers have goals. Winners have systems. - Tim Ferriss, Tools of Titans

Article by:

Aphinya Dechalert

Aphinya Dechalert

Aphinya is a skilled tech writer with field experience in software development, agile, and fullstack JavaScript. She is a dev advocate and community builder, helping others navigate their dev journey.

More posts...

newsletter

🚧 There's more to JavaScript than just console.log()

As a frontend dev, console.log() is necessary. But there's more to debugging than just littering it everywhere. The thing about console.log() is that it's more than just a utility tool that helps us debug. It is also something that you can put inside your error handling process to

newsletter

💡 We need to talk about React

Over the past few weeks, I've been immersing myself in React - specifically, Next.js. While React can be fun, the differences between function and class-based component construction can throw off newbies. It also doesn't help that tutorials mix and match them without much context or explanation. Personally, I've come

newsletter

Dev Freebies and Ways To Upskill

Another week, another newsletter 💌 This week has been pretty intense for me - from playing with Next.js SSR and learning how to use Chakra UI. Here's what I learned from the process of learning something new: * it's always hardest at the start * what you know doesn't become real until

newsletter

Productivity is in the tools you use

As I get back into the groove of weekend projects, I find myself optimizing my workflow. We often associate productivity with our abilities to stay focused. But as software developers and engineers, our tools are as equally important - or more importantly, the extensions and plugins we utilize in our