SSG is dead. Long live cache.

แชร์
ฝัง
  • เผยแพร่เมื่อ 23 ก.ย. 2024

ความคิดเห็น • 136

  • @gradientO
    @gradientO 10 หลายเดือนก่อน +37

    why is Aaron so ridiculously good looking?

    • @carlosescobar5995
      @carlosescobar5995 10 หลายเดือนก่อน +27

      That's how PHP developers looks 😂

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน +11

      I can only thank my mom and dad, I suppose! 🫶

    • @20toninho
      @20toninho 10 หลายเดือนก่อน

      ​@@carlosescobar5995unfortunately for me, not all of us... 😢

    • @codedusting
      @codedusting 10 หลายเดือนก่อน

      Genetics 🧬 doesn't care about equality 😂

    • @tsubasateacher
      @tsubasateacher 10 หลายเดือนก่อน +3

      Bro, you forgot the #nohomo

  • @alexandruaxentioi3006
    @alexandruaxentioi3006 10 หลายเดือนก่อน +20

    Rewritten a bunch of my projects in laravel since a while ago, always amazed about HOW EASY it is compared to any js framework + other complications, really similar to ruby on rails on speed

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน +5

      Yessss love to hear it

    • @JeremyAndersonBoise
      @JeremyAndersonBoise 10 หลายเดือนก่อน +1

      It’s like rails but DHH isn’t involved and PHP is measurably less awful than Ruby. Rails still has some juice but Laravel is eating their FOSS framework lunch nowadays.

  • @phpannotated
    @phpannotated 10 หลายเดือนก่อน +4

    Yay another Aaron video! Thanks for the thought provoking content!
    ☝I do want to point out that the "cache everything with Cloudflare" approach is essentially the same as using a static generator: you're storing your web pages as static HTML and serving them directly. In my opinion, Cloudflare caching is simply another way of doing static site generation. In other words, you've proven that SSG is still the way to go! Always serve static content, unless you have a good use case to make things dynamic.

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน

      Hey Brent! Yeah the point is that you don't need a static site generator, not that you don't need static content. That's kinda the trick! You can get the best of both worlds without having to learn some cobbled together SSG.

    • @phpannotated
      @phpannotated 10 หลายเดือนก่อน

      @@aarondfrancis Makes sense :)

  • @joshr96
    @joshr96 10 หลายเดือนก่อน +4

    The one downside of server side render + cache is the misses but honestly probably not a big deal if your page renders fast enough. In the end probably more comes down to what you enjoy working with and the experience. Most of us are not serving millions of page requests per a day and require the uttermost lowest latency.

  • @randomor
    @randomor 10 หลายเดือนก่อน +6

    This is great idea for your needs. But if your needs are simpler, like only uses images and markdown files, try zero config ssg like zenmd, one cmd ‘npx run zenmd’ and boom you got a static site that is previewable on your file system (no server needed). Disclaimer: I made it last week.

  • @bigjoey1114
    @bigjoey1114 9 หลายเดือนก่อน +2

    Interesting implementation. I think this stack would be great if you had a website pages + blog + webapp that all ran on Laravel. I think the beauty of SSGs is the shear simplicity and portability of the generated HTML files. No PHP updates, Laravel updates, or really any server infrastructure to worry about. I've been loving Hugo lately. BUT, if I need the backend capabilities of PHP and Laravel, this is a nice solution. Thanks for sharing!

  • @hellelo.5840
    @hellelo.5840 10 หลายเดือนก่อน +4

    This doesn't kill static site generators at all, this is just "I want to use laravel instead of next js"

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน +1

      You can use whichever framework you want! That was kinda the whole point. Is next even an SSG?

    • @hellelo.5840
      @hellelo.5840 10 หลายเดือนก่อน

      @@aarondfrancis yes it is, and more

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน

      @@hellelo.5840 cool, sounds great! I'm all for using what you know and like.

  • @roberto_camp
    @roberto_camp 6 หลายเดือนก่อน +2

    What do you think of a Hugo AWS S3 Cloudfront solution, for a customer facing SSL site?

  • @kumaraveldotdev
    @kumaraveldotdev 10 หลายเดือนก่อน +3

    I'm a big fan of your videos and the Sqlite technique was really impressive. 🤩

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน +2

      Wild right? Thank you!

  • @carnavalesenpanama
    @carnavalesenpanama 10 หลายเดือนก่อน

    I love all your videos and content from your personal youtube and planet scale youtube channel. I am always learning something new from you. Thank you!

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน +2

      You're welcome! Glad they are helpful!

  • @engineerallthings
    @engineerallthings 10 หลายเดือนก่อน +1

    Nice video and left me with some questions. Considering Vapor deploys to AWS, why is Cloudflare needed? Wouldn't caching on the gateway and cloudfront achieve the same thing?

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน +1

      TBH I didn't want to go in and figure out Cloudfront caching and I like having Cloudflare in front of everything that I do, it makes me feel warm and fuzzy. Cloudfront might work here just fine!

  • @tannercampbell
    @tannercampbell 10 หลายเดือนก่อน +1

    5:42 why not use the cron/scheduler with Vapor just curios? My guess is to save a little cost and utilize the free GH actions?

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน +2

      Good question! I need to commit the content changes to the repo, so I do it in GHA

  • @ripplesr5655
    @ripplesr5655 4 หลายเดือนก่อน +1

    Dude, what do I have to spend my time on to come close to your massive database of knowledge?

    • @aarondfrancis
      @aarondfrancis  4 หลายเดือนก่อน

      Haha you just have to be curious and try things! That's about it tbh

  • @georgemcwilliams4466
    @georgemcwilliams4466 5 วันที่ผ่านมา

    Let’s be clear, you proved a dynamic site is as fast as a static site by transforming a dynamic site into a static site. The truth is, you wanted to build static site in php and you were clever enough to do it and make it fun. Sometimes the only reason you really need is “it was fun” 😊

  • @LenWoodward
    @LenWoodward 10 หลายเดือนก่อน +1

    Love these techniques. Do you have an anonymized version of this public, or as a package? It all looks so clean!

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน +6

      I do not, but I'll write it up and put it on the very site featured in this video 🤯 Inception. I'll comment here when it's done

  • @tedmoyses2942
    @tedmoyses2942 10 หลายเดือนก่อน

    Came for the clickbait/hot take title, stayed for the implementation. Neat job!

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน +1

      Whew, the ultimate one/two punch! Glad the content lived up to the thumbnail!

    • @tedmoyses2942
      @tedmoyses2942 10 หลายเดือนก่อน

      @@aarondfrancis this approach makes total sense. I have always thought that most SSGs are kinda neat but often felt like they had features shoe-horned into them awkwardly. Why not use a full fat framework you are familiar with that can do so much more. Front matter be damned

  • @pixelations188
    @pixelations188 10 หลายเดือนก่อน

    That mysql+planetscale plug was too smooth 🔥🔥

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน +1

      I'm a pro, what can I say 💅💅💅

  • @bholmesdev
    @bholmesdev 10 หลายเดือนก่อน +1

    Thanks for giving SQLite some love! I'll respectfully disagree SSGs are *dead* (HTML is the simplest cache), but I agree you don't need them if you know server-based frameworks like Laravel

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน +2

      Sounds like Big Astro™ talking, to me! Haha kidding kidding. Yeah HTML is great, truly my first love. As with almost everything I make videos about, I'm trying to advocate for things I like and offer a different way of doing things, different than what most people are talking about on tech twitter.

    • @bholmesdev
      @bholmesdev 10 หลายเดือนก่อน

      Haha nice, we need that! I've started playing with libraries from the laravel world like Alpine thanks to these vids. I'll need to try those cloudflare cache settings too 🙌@@aarondfrancis

  • @JeremyAndersonBoise
    @JeremyAndersonBoise 10 หลายเดือนก่อน +1

    Protip, “it doesn’t.”
    If your site needs to process more than 10k requests per minute consider using something other than Laravel. Don’t make assumptions, make measurements.

  • @Pongant
    @Pongant หลายเดือนก่อน

    Bit much for a markdown based static site no?

  • @JeremyAndersonBoise
    @JeremyAndersonBoise 10 หลายเดือนก่อน

    Laravel with a well-configured CDN, S3-style object storage and solid caching is darn fast, within a certain scale…one that most sites/apps will never get anywhere near exceeding.

  • @DaviMartins99
    @DaviMartins99 10 หลายเดือนก่อน

    Hey, Aaron, your website looks great and this was very insightful!
    P.S: I noticed a bit of horizontal scrolling on the homepage, not sure if it's just my PC.

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน

      Wuh oh! Thanks for the report, I'll check it out

  • @JLarky
    @JLarky 10 หลายเดือนก่อน +1

    "static sites is the only way to get fast response", well, no, static sites is the only way to copy paste my website to any place like 15 years later and it still works

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน +3

      Static sites, sure. When was the last time you tried to run even a two year old static site *generator* though? That's what this video is about. Thanks for stopping by, as always. One day I'll make a video you agree with!

  • @simonnjoroge933
    @simonnjoroge933 9 หลายเดือนก่อน

    It amazes me how clean your glasses are, mine are always dusty. 😊

  • @JustinJackson
    @JustinJackson 10 หลายเดือนก่อน

    This was great. It gave me a bunch of ideas for my site. Thanks!

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน

      Oh nice! Can't wait to see

  • @SRVblueshero1
    @SRVblueshero1 6 หลายเดือนก่อน

    Even though this is about avoiding SSGs, do you think it’s possible to use PHP as an SSG?

  • @yannicksans7141
    @yannicksans7141 หลายเดือนก่อน

    Clever ! Like It ....

  • @ricko13
    @ricko13 2 หลายเดือนก่อน

    1:31 that comment aged like milk Aaron 😅

  • @andresgutgon
    @andresgutgon 9 หลายเดือนก่อน

    Great video! one question, you also pay the Vapor fee no?

    • @aarondfrancis
      @aarondfrancis  9 หลายเดือนก่อน

      Yup! I pay for it for business stuff so I'm paying either way

  • @adampatterson
    @adampatterson 10 หลายเดือนก่อน

    Is there an easier way to find the channel Id other than viewing source and searching for channelId in the JSON?

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน +1

      Huh thats a good question. It shows up in the URL if you go to TH-cam studio, but that presupposes it's *your* channel, which it might not be. I'm not sure other than that!

    • @adampatterson
      @adampatterson 10 หลายเดือนก่อน

      @@aarondfrancis oh so it does!

  • @ChrisSmith105
    @ChrisSmith105 10 หลายเดือนก่อน

    PHP 8.1?! What is this the stone age!? Kidding... nice video. Will do on my site. May video make.

  • @asparuhnestorov
    @asparuhnestorov 10 หลายเดือนก่อน

    I have pretty good internet but could not get below 500ms loading /lists. Why your time is so different?

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน

      haha you must've gotten it when I was playing with Vapor's gateway v2 without cloudflare on. Try again!

    • @Nikola-Video
      @Nikola-Video 10 หลายเดือนก่อน

      @@aarondfrancis Yep, now its down to 150ms but I am in Europe. I dont know if cloudflare are supposed to use CDN for the cache ....

  • @vishaldinesh
    @vishaldinesh 10 หลายเดือนก่อน

    Hi Mr. Dunphy, although I'm a JS dev I love your videos keep them coming

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน +1

      Happy to be of service!
      - Everyone's favorite sitcom dad (apparently)

  • @pablorgto
    @pablorgto 10 หลายเดือนก่อน

    Please, make an video about the Drupal 10?? Thank you!!!

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน

      I don't know anything about Drupal!

  • @MrAmG17
    @MrAmG17 9 หลายเดือนก่อน

    Sadly the links are not presable on youtube app. Also can't copy it easily..

    • @aarondfrancis
      @aarondfrancis  9 หลายเดือนก่อน

      Huh?

    • @MrAmG17
      @MrAmG17 9 หลายเดือนก่อน

      @@aarondfrancis you need to add to your urls in desc :)

    • @aarondfrancis
      @aarondfrancis  9 หลายเดือนก่อน

      Ah cool. Thank you!

  • @feldinho
    @feldinho 10 หลายเดือนก่อน

    wait! you have a PODCAST?! subscribing, brb

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน

      Heck yeah! mostlytechnical.com

  • @codedusting
    @codedusting 10 หลายเดือนก่อน

    How large of an application a SQLlite can handle?

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน +1

      No idea, literally the first time I've ever used it in prod

    • @codedusting
      @codedusting 10 หลายเดือนก่อน

      @@aarondfrancis Thanks.

  • @MightyMoud
    @MightyMoud 10 หลายเดือนก่อน

    Are you telling that this is better than a “full stack” NextJS app with a “server-less” Postgres for my blog? Noooooo way!

  • @shmuelbisberg4396
    @shmuelbisberg4396 10 หลายเดือนก่อน

    Sqlite on prod use case???
    Very interesting video!

  • @GergelyCsermely
    @GergelyCsermely 9 หลายเดือนก่อน

    Thanks

  • @anasouardini
    @anasouardini 10 หลายเดือนก่อน

    WOW! a new way of presenting the same good gold SSG (though implementing it the hard way aka. "I prefer php more than js").

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน

      My old SSG was PHP also!

    • @anasouardini
      @anasouardini 10 หลายเดือนก่อน

      ​@@aarondfrancis
      Ok, good to know, but that was not my main point: SSG is still in the core of your approach.
      Maybe, by "dead", you're referring to the current implementations, in that case, what are the limitations that pushed you towards implementing your own?
      Nevertheless, have you considered ISR/SSG+serverless? Just asking.

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน

      @@anasouardini I don't think my approach is fundamentally SSG tho. It's just a Laravel app that's super cached. Static content is great, is the SSG part that I don't think we need anymore

    • @anasouardini
      @anasouardini 10 หลายเดือนก่อน

      ​I re-watched your video, but I still have the same conclusion.
      - You like static content
      - You don't like the generation (?) of it?
      The only difference I see is the output destination.
      The way already existing SS tools output/generate SS is what you don't like, I think. If so, what is the reason? I'm curious.

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน

      In my view, a static site generator generates a bundle of content, usually html and client side JS, that is then shipped out to some destination. My site is not generating a bundle of static content... It's serving html in response to requests, and then it's cached. That's why it's not a static site generator? I dunno man.

  • @daethic421
    @daethic421 9 หลายเดือนก่อน

    A-Aron, what code editor are you using please?

    • @aarondfrancis
      @aarondfrancis  9 หลายเดือนก่อน

      PHPStorm

    • @daethic421
      @daethic421 9 หลายเดือนก่อน

      @@aarondfrancis Thanks AAron! Have a great day mate

  • @StingSting844
    @StingSting844 10 หลายเดือนก่อน

    Not this MF with another great video i can't skip

  • @languagelearningexperience6814
    @languagelearningexperience6814 10 หลายเดือนก่อน

    This title made me happy lol

  • @tsubasateacher
    @tsubasateacher 10 หลายเดือนก่อน

    Thanks! Bring back the cache!

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน +1

      Cache it all!

  • @nym49
    @nym49 10 หลายเดือนก่อน

    "Sci-fi Books - This list has its own page."
    LIE!
    I'm not serious, of course. Just a heads up: It currently returns an error 500.
    Really curious to see what's on your list.

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน +1

      Oh shoot! Thanks. One sec

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน

      aaronfrancis.com/books fixed! ❤️

  • @HaifengZhu-pn3uq
    @HaifengZhu-pn3uq 10 หลายเดือนก่อน

    is your personal website made by static site generator?

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน

      Muy personal website is made using the methods in this video, which features my personal website. It's just Laravel

    • @HaifengZhu-pn3uq
      @HaifengZhu-pn3uq 10 หลายเดือนก่อน

      @@aarondfrancis Thanks, is Laravel slower than next.js?

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน

      @@HaifengZhu-pn3uq no idea. Apples and oranges

  • @feldinho
    @feldinho 10 หลายเดือนก่อน

    SSG is just acoustic cache

  • @TonyMessias
    @TonyMessias 10 หลายเดือนก่อน

    Wild. I love it.

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน

      Madlad, as they say

  • @MightyMoud
    @MightyMoud 10 หลายเดือนก่อน

    I have a genuine question: why do you guys have so many comments in Laravel codebases?

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน

      In the core? I dunno honestly, it's a Taylor thing. I like it because I source dive a lot and I like seeing what the thought process was behind a piece of code!

    • @MightyMoud
      @MightyMoud 10 หลายเดือนก่อน

      But even in the code you just showed. You had a comment on top of the call to purge the cache. In my company the PHP side codebase is full of comments too. It seems like a PHP developer habit… I find it odd tbh

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน +1

      Oh ha, I dunno! Maybe it is a cultural thing! I'll start paying attention 🤔

    • @hayopapayo1717
      @hayopapayo1717 10 หลายเดือนก่อน

      ​@@MightyMoudin Laravel you most often create files per command line. The file has boilerplate code with comments and I guess I am to lazy to delete the comments. But might be different in other places 🙂

  • @nonnnth
    @nonnnth 10 หลายเดือนก่อน

    Everything can be the fastest application framework in the world. Angular did it, maybe Laravel can do it too 😁

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน

      Haha true. Laravel is indeed pretty fast already!

  • @jsk9559
    @jsk9559 10 หลายเดือนก่อน

    Great video!

  • @grugbrain
    @grugbrain 9 หลายเดือนก่อน

    "I just happen to work there" 🤣

  • @SickBeard
    @SickBeard 10 หลายเดือนก่อน +1

    Static site generators are dead ... proceeds to serve (essentially) static content via CF 🤣

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน

      Yes (unironically)

  • @pierbover
    @pierbover 9 หลายเดือนก่อน +1

    yeah but free hosting

    • @aarondfrancis
      @aarondfrancis  9 หลายเดือนก่อน

      Where do you like to host?

    • @pierbover
      @pierbover 9 หลายเดือนก่อน

      @@aarondfrancis static sites? These days Netlify and Clouflare but I've used pretty much anything under the sun.

    • @aarondfrancis
      @aarondfrancis  9 หลายเดือนก่อน +1

      Nice, thanks. I've got ideas™️ so that's helpful

  • @zinatziaee5000
    @zinatziaee5000 10 หลายเดือนก่อน

    🎉

  • @swakemudi8682
    @swakemudi8682 10 หลายเดือนก่อน

    ssg are dead. however static site is immortal

  • @jesseleite
    @jesseleite 10 หลายเดือนก่อน

    You know, for someone who hot takes against hot takes...

    • @aarondfrancis
      @aarondfrancis  10 หลายเดือนก่อน +1

      Hot thumbnail, lukewarm take