Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
90s_dev
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
32 ms
·
451.
▲
by
90s_dev
1y ago
Ah, fair enough. So it is still stringly typed, it's just verified at compile time. Which I guess is true about all compiled functions ever .
452.
▲
by
90s_dev
1y ago
If it's just a variable in scope, you could do: if (condition) { // new scope const jsx = // ... return <foo/> } In practice, "variable in scope" is essentially the same as
453.
▲
by
90s_dev
1y ago
How is that not also stringly typed?
454.
▲
by
90s_dev
1y ago
Yeah it seems fine. I wouldn't be strongly opposed to it. Standardization of either is better than nothing.
455.
▲
by
90s_dev
1y ago
True, but those were designed in the 80s or 90s. I guess I'm thinking of embedded scripting languages designed since ~2015.
456.
▲
by
90s_dev
1y ago
I don't think that's the reason behind Lua's syntax. I think it was designed specifically to be extraordinarily unambiguous, clean, and simple, which it is.
457.
▲
by
90s_dev
1y ago
A few times over the past 15 years, the HN mods have made it clear to me that you only get the HN spotlight once every few months. So this was my one chance for mid 2025 to release it right. That's okay, lesson learned is the important
458.
▲
by
90s_dev
1y ago
Fun story, I once walked about 11 hours because of my stupidity, and at the end my heart wouldn't stop racing even after I passed out in a bed. I woke up a few times with my heart still racing, and that whole day and night I wasn'
459.
▲
by
90s_dev
1y ago
> I once tried to burn 3,000+ calories per day using just walking. You'll generally burn about ~2k cals per day just being alive. An intense workout for an hour can burn maybe 500 on top of this. I think your math might be off somew
460.
▲
by
90s_dev
1y ago
> Note that nothing in the script is run automatically when the script is loaded, as happens in many other scripting language. The host application decides which functions and filtermaps it extracts from the script and when to run them.
461.
▲
by
90s_dev
1y ago
> Finally, we want a language that is easy to pick up; it should feel like a statically typed version of scripting languages you're used to. It looks like Rust. All Rust scripting languages do. Is this true for all other languages?
462.
▲
by
90s_dev
1y ago
Interestingly, Ghostbusters (1984) was rewritten to have the team being a startup, because everyone was beginning to start up their own businesses at the time.
463.
▲
by
90s_dev
1y ago
> *It's NOT a proposal to incorporate JSX into the ECMAScript spec itself.* It's intended to be used by various preprocessors (transpilers) to transform these tokens into standard ECMAScript. (Emphasis theirs.)
464.
▲
by
90s_dev
1y ago
True. Then can you suggest a standardized ECMAScript JSX proposal that doesn't turn this into a "children" key on an object? Would you just transform it into an array? ["foo", { bar: qux }, "baz"] ?
465.
▲
by
90s_dev
1y ago
Hi, I'm the guy who wrote this proposal. tl;dr: My proposal transforms <foo bar={qux}>bla</foo> into { [Symbol.for('jsx')]: 'foo', bar: qux, children: "bla" } It's self-contained, gen
466.
▲
by
90s_dev
1y ago
This is a known ambiguity in JSX, to the point where TypeScript gives this error: > 'children' are specified twice. The attribute named 'children' will be overwritten. ts(2710)
467.
▲
by
90s_dev
1y ago
Then is the solution to have write-only be the default for muts, so that they start out write-only at least , but can also be made to be read-write either (a) in given circumstances of creation, or (b) after certain operations on them, o
468.
▲
by
90s_dev
1y ago
Given <foo bar={qux}>bla</foo> React used to transform it into React.createElement("foo", { bar: qux }, "bla") Now it transforms it into import _jsx from "react/jsx-runtime"; _jsx("fo
469.
▲
by
90s_dev
1y ago
I made this proposal because JSX is more generally useful than generating HTML. You can use it for configuration, or views for other GUIs like I do in https://90s.dev/os/ or to describe basically any kind of tree.
470.
▲
by
90s_dev
1y ago
Well?? Did it sign it???
471.
▲
by
90s_dev
1y ago
There is a difference though between showing off cool stuff and having the potential to show off cool stuff. I released my app in the latter phase, not the former, which is what I wanted to do. To be honest, I was just having a really bad d
472.
▲
by
90s_dev
1y ago
Sorry, what? Did you just say NASA uses Clojure ?? That must be a pretty big honor for Rich.
473.
▲
by
90s_dev
1y ago
Interestingly, I didn't know Vue had a thing called a Ref until about a week ago. Yet my Refs have a very similar design. Though I do think my Refs are much better and more generally useful. In fact, I think my Refs might be a genuin
474.
▲
by
90s_dev
1y ago
> Assertions for programmer mistakes; errors for user mistakes That's been the general mantra for at least a decade or two. And I think it's right.
475.
▲
by
90s_dev
1y ago
Write into uninit'd buffers was one of the pain points of Rust for the creator of the new open source "edit" program for Windows[1]. I wonder what he thinks of this article. > Another thing is the difficulty of using unini
476.
▲
Proposal for Standardized JSX
(vanillajsx.com)
35 points
by
90s_dev
1y ago
|
45 comments
477.
▲
by
90s_dev
1y ago
Thanks. I failed to capture the essenence of what my project is. The APIs are really what's exciting. But you can't see APIs, they're like the wind, you have to see them in action, through their side effects. I should have wa
478.
▲
by
90s_dev
1y ago
> No. I achieved this because the code contained very little of the real value. That was all stored in my head. The design was in my head, and with hindsight I could see all its flaws. I was therefore able to create a much more efficient
479.
▲
by
90s_dev
1y ago
Most people think of DSLs as a language you can create within a language . All the things you named are either entire languages themselves like HTML, SQL, and the shell family, or formal extensions of existing languages like JSX. A DSL
480.
▲
by
90s_dev
1y ago
In the immortal words of Pitch Meeting's Screen Writer Guy, I'm gonna need you to get allll the way off my back about the name being innacurate.
More ›