News for hackers. Stuff that matters.
Re:Ask HN: How to deploy a React App to a static blog? by Something1234 on Monday July 29, 2024 @01:55PM (#41102306)
I would use vite to build it. Avoid next like the plague.

Vite is great for things like this. I've also stuck them in by themselves using tsc and react-min.js or maybe I ran it through babel by hand. IDK.

https://www.henryschmale.org/2022/03/14/rsa.html

Re:Ask HN: How to deploy a React App to a static blog? by epelesis on Monday July 29, 2024 @03:22PM (#41102971)
Yep Vite is the way to go, especially if it's a static site. While server side react frameworks like Next may technically support static sites, it feels like an afterthought and IMO it adds too much unnecessary complexity.

Here's a shameless plug (and demo) for a static Vite site I deployed with Cloudflare Pages. This tech stack has been awesome to use (and free): https://bufo.nedellis.com/

Re:Ask HN: How to deploy a React App to a static blog? by solardev on Monday July 29, 2024 @01:13PM (#41101977)
Just use Astro for this. https://astro.build/

It's one of the lighter React frameworks and perfect for a simple static blog.

You can of course do it with Next too, but it's overkill for a simple blog.

Re:Ask HN: How to deploy a React App to a static blog? by pestatije on Monday July 29, 2024 @12:33PM (#41101671)
i use next in export mode
Re:Ask HN: How to deploy a React App to a static blog? by siamese_puff on Monday July 29, 2024 @06:11PM (#41104259)
I think Vite will solve all your problems without coupling yourself to a particular framework too much