website-astro/src/content/articles/en/the-day-I-jamd.mdx

78 lines
3.9 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

---
title: The day I Jamd
subtitle: A story of unusual tools and fun gambles.
lang: en
slug: "the-day-I-jamd"
excerpt: Ooh, yeah! All right! Were jammin
tags: ["Dev", "Jamstack"]
type: articles
createdAt: "2020-10-08T09:00:00.000Z"
updatedAt: "2022-12-27T15:40:06.000Z"
---
import AstroImage from "../../../components/AstroImage.astro";
export const wordpress = "https://assets.nardu.in/wordpress_8ee6f54b98.jpeg";
export const strapi11ty = "https://assets.nardu.in/static_2c0d9f1eb8.jpeg";
## The not so easy choice
When I was still using Wordpress for my personal website, I thought it would be nice to try [OpenLiteSpeed](https://openlitespeed.org) webserver. Being a designer, I always like to have a graphical interface and I heard OLS had very nice caching and overall performances.
## FIGHT!
A few years later, I learned about Jamstack and its incredible potential. Not being impulsive at all, I chose to entirely remake my website with tools like [11ty](https://www.11ty.dev/) and [Strapi](https://strapi.io/).
I remember Strapi still being in alpha/beta and colleagues telling me it was a risky gamble, especially since I was pretty new to the node.js world.
> Open source and french? Sign me up!
So I started recreating my website identically with 11ty and Strapi. Same hosting on a Digital Ocean droplet, same webserver, same content. I had done a fair amout of performance optimizations on my wordpress install so I was eager to compare the results with the new static version.
Boy did they exceed my expectations! With almost no optimization on the static side, I got the following results.
### wordpress
<AstroImage
src={wordpress}
width="728"
height="412"
alt="Performance score of 53/100 on Wordpress."
/>
Despite a lot of efforts I could not do better. Im no expert in caching, do not use CDN and relied on plugins to achieve a lot of stuff (php not being my strongest skill 😬).
### 11ty + strapi
<AstroImage
src={strapi11ty}
width="728"
height="412"
alt="Performance score of 97/100 on jamstack."
/>
Almost **zero** special configuration (I was too anxious to test) and I reached an awesome score. I know lighthouse scores are not everything but hey, **53 vs 97**… Ill take it!
## Now kiss 🥰
Both of these approaches have their benefits and drawbacks. As a freelance, my clients often prefer or ask for Wordpress because of its reputation. I always present a Jamstack alternative when possible but its still scary to most compared to Wordpress. I feel however that its going to be easier to use Jamstack with time.
## I did it again…
Here we are now, a quarantine and a few months later and this website is running with… [Nuxt.js](https://nuxtjs.org/). I know, Im sorry, I couldnt resist the latest [nuxt content](https://content.nuxtjs.org/) functionnality.
So I re-did everything again… and let me just say: **wow**, what an experience!
I **love** developing with Nuxt. Using nuxt content allowed me to focus on design and, well, content.
No more Apollo client and graphQL query, only markdown and a few promises.
Dont get me wrong, I really like working with Strapi and its graphQL capabilities but for the purpose of this website, nuxt content does it (extremely well).
Im still using Strapi as a way to upload, store and manage images, videos, gifs, etc. It might be too much for this use case but I like to know that I can still go back to it if I want to! Also, I spent quite a bit of time setting it up with OpenLiteSpeed and Im still too attached to this accomplishment to let it go.
## In the end
Wordpress, Jamstack, vanilla everything… Does it really matter? For me, the dev experience was far more enjoyable working with 11ty, nuxt.js and strapi than with Wordpress.
On the performance and accessibility side, it also seems to be the better/smarter choice. It might not be everytime! ¯\\\_(ツ)\_/¯
Cant wait to learn [astro](https://astro.build/) and start from scratch again!