News for hackers. Stuff that matters.
Re:Start a Fucking Blog by mikojan on Tuesday January 03, 2023 @11:23AM (#34233493)
> So how well is a static site generator suited for this? Do I want to build thousands of pages every time I start the site locally?

Take a look at Astro[1]. Astro comes with a development server and it will not build a thing unless you want it to.

Also, in contrast to classic static site generators Astro relies on components instead of templates which reduces cognitive complexity dramatically (to me anyway).

[1]: https://astro.build/

Re:Start a Fucking Blog by azangru on Tuesday January 03, 2023 @04:31PM (#34238375)
Yeah, I've been eyeing Astro, and wondering whether I like it or Eleventy more. What worries me about Astro is that its internals must be very complex, since it's trying to support all the component frameworks and libraries out there. As a result, I heard some complaints about unaccountable problems with my favorite component library, Lit. I am also very surprised that the choice between SSG and SSR mode in Astro seems to be all-or-nothing, rather than a configuration that would allow SSG-ing some pages and SSR-ing others.

But yeah, its syntax, with an out-of-the-box support of typescript, looks more enticing than Eleventy's nunjucks or webc, or its serverless plugin. Good to know that Astro doesn't prerender all pages in dev mode either.

Re:Start a Fucking Blog by jjdeveloper on Thursday January 05, 2023 @06:51AM (#34258523)
They now have an experimental flag that allows some pages to be SSR and others SSG. So this is now possible