Better HN
topnewbestaskshowjobs
Log inSign up

mb2100

119 karma · joined Jan 26, 2013 (13y ago) · 118 submissions

http://github.com/mb21

hacking on https://mastrojs.github.io

Submissions

comment 5d ago · link · parent

uh, that's almost as big as React + React DOM :-(

comment 1mo ago · link · parent

There are JS libs (like Reactive Mastro [1]) that go well with writing otherwise vanilla HTML/CSS/JS, and there are libs (like React) where you're quickly sinking into a mud of abstractions and have to fight the reactivity runtime when you try to write vanilla JS.

[1]: https://mastrojs.github.io/reactive/

comment 1mo ago · link · parent

That's weird, considering the guy who put the fetchable.org website up works at Netlify.

comment 1mo ago · link · parent

Not quite. Perhaps you were thinking of "ethnic cleansing" ?

comment 2mo ago · link · parent

Short answer: no, not necessary. Long answer: https://mastrojs.github.io/blog/2025-11-27-why-not-just-use-...

comment 2mo ago · link · parent

Is understanding Dutch (reading and listening) good enough?

comment 2mo ago · link · parent

They're not experienced with git, but still use the command-line? Interesting. Or would you think a jj GUI would help them?

comment 2mo ago · link · parent

2. You must have never written Haskell.

comment 4mo ago · link · parent

how do I do that? :-)

comment 4mo ago · link · parent

Agreed, but uhtml-ssr looks a bit dated. If you want a html tagged template literal lib with no dependencies, see for example:

implementation: https://github.com/mastrojs/mastro/blob/main/src/core/html.t...

docs: https://mastrojs.github.io/docs/html-components/

comment 4mo ago · link · parent

No dependencies. No build step. Just a simple web framework. Implemented in just ~800 lines of TypeScript.

https://mastrojs.github.io

comment 4mo ago · link · parent

Some people even like stinky!

comment 4mo ago · link · parent

This. Cannot believe it too so long for somebody to finally mention progressive enhancement.

comment 5mo ago · link · parent

> Backend and UI communication goes through in-process channels, not socket-based IPC

Are they running the frontend and backend in the same process? Sounds a bit dangerous security-wise?

comment 5mo ago · link · parent

This. "No loading animations" works if you rely on the browser's loading indicators that all users will be familiar with.

@OP, if you're up for a rewrite of the frontend, happy to help you get started with https://mastrojs.github.io

comment 5mo ago · link · parent

the achilles heel of SPAs everywhere.

comment 5mo ago · link · parent

right? or give me GitHub issues before the React rewrite – at least they loaded fast...

comment 6mo ago · link · parent

What AI is doing to the jobs of programmers feels very familiar to a lot of us frontend developers – because it has happened to us before.

comment 6mo ago · link · parent

Yeah, while you certainly can write semantic HTML with Tailwind, it absolutely doesn't encourage it. It's funny how Tailwind is conceptually going back to inline styles.

But sure, if you have <Title>, <Header> and <Button> components etc. instead of using HTML elements <h1>, <header>, <button> etc. directly, then why not stuff the CSS into the components as well? It all depends on whether you prefer to use components, HTML elements or a combination as your favourite abstraction.[0]

[0]: https://mastrojs.github.io/blog/2025-11-27-why-not-just-use-...

comment 6mo ago · link · parent

Sounds similar to https://nightride.com ?

comment 6mo ago · link · parent

That's because Apache is basically what today's JS crowd would call a "file-based router", and then the app implements the actual routing in that index.php file. Just like early SPA stored the route in a hash. It's funny how history repeats itself.

I've gone back and forth on file-based vs programmatic routing. But each has pros and cons, so in the end I implemented both in Mastro: https://mastrojs.github.io/docs/routing/

comment 6mo ago · link · parent

What's the main motivation for considering Rust?

For what it's worth, in my last experience with Bun[0] I ran into a couple of bugs where it seemed Rust could have helped, e.g. using Bun.write

[0]: https://mastrojs.github.io/blog/2025-10-29-what-struggled-wi...)

comment 7mo ago · link · parent

Agree that TypeScript is nice, especially for sharing templates and types between server and client. But you can still use TypeScript on the server without sending it all to the client, and without a complex and insecure protocol like RSC. I’m working on making this as simple and dependency-free as possible: https://mastrojs.github.io

comment 7mo ago · link · parent

That was exactly my experience as well, hence I created a "Minimal Astro": https://mastrojs.github.io

25.

Deno Employees Leave(dbushell.com ↗)

6 points · by mb2100 · 8mo ago · 1 comment

comment 9mo ago · link · parent

Yeah, for that a git-based CMS like Sveltia is really nice.

And for people that actually want to learn a bit of HTML, CSS and JavaScript, Mastro JS is as simple a static site generator as I could make it.

comment 9mo ago · link · parent

if you're not using CSS modules, why would you import the css file into your javascript? But anyway, I think we agree. Feel free to read the linked blog post ;-)

comment 9mo ago · link · parent

button, .button { /* my button styles */ }

comment 9mo ago · link · parent

If everything in your code is a React component, I get why you would just want to write the styles right there.[0] Then again, why write `<Button>` if you could just write `<button>` and style it with standard CSS.

[0]: https://mastrojs.github.io/blog/2025-11-27-why-not-just-use-...

1234