Hacker News new | ask | show | jobs
by davepeck 834 days ago
I dig Astro and use it to build my blog and several other tiny mostly-static sites. I'm not sure that the hosted database service fills a need I have but, in general, supported SQL integration seems like a useful addition.

As an aside: there are days when I wish I could avoid using the Astro component model entirely, do everything in Preact (or whatever), and still use the `client:*` directives when appropriate. I realize this is easier said than done and also probably not a reasonable thing for Astro itself to try and target -- but moving between Astro components and framework components always has just enough friction that it's something I think I'd enjoy using.

1 comments

This is probably the main reason I wouldn’t choose Astro for personal projects where it’s otherwise a great fit. I think it would have been a more reasonable thing earlier on in product conception, but quite a lot of assumptions are now baked into their own custom template language. Which I’m sure is quite a nice template language, but it’s already hard enough to get all the tools to work nicely together without adding another one.
Yeah, I started poking at Vite to see how much work it would take to build an island-architecture-for-preact tool on top of it. It looks doable.

Out of curiosity, when you're building a mostly static site that might want occasional islands of interactivity, what do you reach for instead?

> mostly static site that might want occasional islands of interactivity

is exactly what I made this for https://github.com/bensmithett/tropical-utils/tree/main/pack...

It’s a little more verbose and doesn’t quite have the ergonomics of Astro client:* directives, but it does the trick for me.