102 points · by ilamont · 20h ago · 87 comments
For eg. compare this:
``` Window { textColor: "slategray" property int v: 40
ColumnLayout {
id: layout
anchors.fill: parent
spacing: 20
Text {
id: number
Layout.alignment: Qt.AlignHCenter
font.pixelSize: 70
text: v
}
ProgressBar {
id: progressBar
Layout.alignment: Qt.AlignHCenter
value: v/100
color: v < 50 ? "dodgerblue" : "turquoise"
}
}
MouseArea {
anchors.fill: parent
onClick: v = (v+20)%100
}
}
```with Declare:
``` App [ textColor = slategray,
group: View [ x = center, y = center, width = 80%,
layout: SimpleLayout [ axis = y, spacing = 20 ],
number: Text [ width = 100%, textAlign = center,
fontSize = 70, fontWeight = bold, text = { "" + v } ],
bar: Gauge [ width = 100%, value = { v },
tint = { v < 50 ? cool : warm }, accessibilityLabel = "v" ],
hint: Text [ width = 100%, textAlign = center,
text = "click anywhere to change v" ]
],
v: number = 40,
cool: Color = dodgerblue,
warm: Color = turquoise,
onClick() { v = (v + 20) % 100 }
]
```I'm happy enough the with xml-based tsx - if only to differentiate between declared structure v.s. expressions.
Especially (with what I've seen briefly) of Solid v2.
But I'm sure I could get used to the above quick.
Additional to it it may have more fps, but feels less snappy.
I still use it as it's better than electron, but still makes me sad.
But I have also seen really well optimized QtQuick applications that ran at 60 fps on a single core imx6 while playing video, applying all kinds of effects on the video...
The hardest similar problem I've faced was teaching agents aesthetics for a drawing style. What worked: I hand-engineered an interpretable feature space for SVG diagrams, and used the feature vectors of exemplars as the style target for generation. The agents then wrote code one-shot that drew as I liked.
AI is a kit, not a car where you turn the key. We're all facing the same issues, and many of us are constantly engineering infrastructure to "fix" AI to our needs. Consensus forms fast, and much of this engineering becomes available out of the box if one instead just waits a few months. Reification of state between sessions is the big one we all used to do by hand, that's now standardized.
Feature spaces would work for teaching comment and writing styles. Try it!
Before I fixed my language, my original was "A key component of LLMs is a semantic embedding into a large vector space. I struggled with teaching LLMs aesthetic judgement, and what worked was building hundreds of sensors to measure aspects of an SVG diagram, and embed art that I liked into a corresponding vector space. Then I could tell an LLM coding agent "draw like this!" and it could, one-shot."
"Two vectors, and the one invariant that binds them." WHAT ARE YOU TALKING ABOUT
At this point I don't see any pros compared to any existing reactive framework.
For now, I would urge project creators to start using Neon for writing docs and landing pages. It's significantly better out of the box.
I don’t think it is worth giving my agent to peruse either, because it will get poisoned.
Hard skip. And maybe even block.
Claude has ruined Solarized for me. As soon as I see that theme (light or dark), I quit the tab. I don't even need to start reading.
I am making some software currently which has a solarized background but white containers on top.
The claude solarized + burnt orange is quite unpleasant, however.
Meanwhile, Claude has become immune to skills that try to tame its writing style. I think they’re prioritizing preventing distillation vs their own product UX, which is a shame.
If one starts with AI text, it is like seeding their mind with already completed details, and so they cannot see anything beyond the pre-existing structure it has created for them. One has to start from a blank slate to avoid this fate.
Anyway, it's probably more existential dread than laziness. Y'all just gonna point your LLM at it in real world use.
It should probably say up front that this is an npm package along with the tooling for it, and the output runs in a browser.
"This page is written in it. By an LLM."
But, there's a lot of actual craftsmanship in the project. (Or at least it's taken real work and thinking over a long period of time; you be the judge).
Do take a look at the FAQ, and "Why" under "Learn", you might find things you like. And the calendar example too.
I fell into a bit of a trap on the prose, which is ironic considering I've edited actual publications and been a journalist... years ago
Appreciate the reactions - and ahem , point very much taken on marketing-y prose and admittedly (some) AI prose diction in sections. Bad on me.
All that being said there is actual depth here, it’s not a thin layer over React. Even if you have no interest in agent-driven coding - but are interested in front end dev - I think you’ll find some interesting bits. The language and framework allow a lot in the way of design expressiveness without escape hatches. The component library is self-hosted. Animation built on fine grained constraints. Accessibility. Runs on DOM or without DOM.
And yes it is typed.
Btw if you happen to remember a language / framework called OpenLaszlo … from many years back — this is a sort of successor. I co-founded the company that created that project.
[1] https://kotlinlang.org/docs/multiplatform/compose-multiplatf...
Honestly, Jetpack Compose and SwiftUI already nailed concise declarative UI, and they have the huge advantage of living inside full-blown languages like Kotlin and Swift so you don't hit a wall when logic gets complex
A more closed language would be even more effective on this dimension but I didn't want to give up expressiveness / ability to make truly custom UX. That's been a big part of this project...
(this is my project...)
- Move docs to llms.txt too
- Make one click copy prompt button for starting with an agent
- Explain clearly how it can integrate with React or Vue - if I can embed a module in my already existing app - thats a great way to transition over time.
- Play the “Agent” card more - these days nobody will learn new DLL, but having a way to quickly test it with my agent would convince more people to give it a try
Snippet -
```
document ::= ( comment | blank )* screen-line body
body ::= ( element-line | comment | blank )*
element-line ::= indent kind [ name ] meaning* [ modifiers ]
```
```
document = { template } ;
template = "@template", identifier, newline, { node }, "@end", line-end ;
node = group | row ;
group = "<", identifier, ">", newline, { node }, "</", identifier, ">", line-end ;
row = atom, { "|", atom }, line-end ;
atom = reference | component | spacer ;
reference = "[[", identifier, "]]" ;
component = "[", label, [ "|", identifier, { "|", property } ], "]" ;
property = identifier, "=", value ;
value = json-scalar | binding ;
label = label-part, { label-part } ;
label-part = literal-text | escape | binding ;
binding = "{", identifier, { ".", identifier }, "}" ;
spacer = "..." ;
line-end = newline | end-of-file ;
```
Still evolving.
Core idea is to be able to define interfaces in a minimal language, without going into too much details about attributes, say height, width, etc
https://hofstadter.io/code-generation/
I'm migrating / renaming / cleaning up the project this week
I'm using "a transpiler" loosely to cover when the input is a DSL and output is something like react, tanstack, node - but tech choices are flexible here
Isn't HTML a DSL for UI? What's wrong with it?
“Show boxes”?
UI used to strive for making it easy for users to understand the software’s mental model, current state, and possible actions. Now it’s about looking cool (the same as the other cool kids).
XAML was a notoriously bad idea.
This doesn't look much better than that.
Language is extremely annoying.
I hate it