3 ms·
It seems as though it's entirely code driven. We've largely decided that declarative langues (html, xaml) are better for building user interfaces. This looks mo
by flukus 10y ago
It seems as though it's entirely code driven. We've largely decided that declarative langues (html, xaml) are better for building user interfaces. This looks more like swing for the web.
- Kinnard 10y agoWhy are declarative languages better for UI?
- yrezgui 10y agoThey're easier to read and code. Check out XAML for C#, it's dead simple. But one of their main problem is they advertised for too long (I remember waiting for ages) and we didn't get the 60 fps. It wasn't as fast as announced and painful to integrate.
- flukus 10y agoI'd say check out knockoutjs instead, way simpler than xaml.
- flukus 10y agoBecause it provides I nice separation between the "static" parts of a program, the UI, and the dynamic parts, the data. The first demo of this on the other hand, has html embedded in javascript strings. A program of any complexity written like this would quickly turn into a big ball of mud.
- Kinnard 10y agoI'm somewhat skeptical of this separation of concerns
- flukus 10y agoI'd encourage you to try it out: http://jsfiddle.net/rniemeyer/LkqTU/ http://jsfiddle.net/rniemeyer/LkqTU/
- iamleppert 10y agoIt's possible to turn any codebase into a big ball of mud. Declarative languages are just a tool, like object oriented languages are. And arguably, if you choose a language based upon its ability to help you define what is "dynamic" vs. "static" you've made some mistakes.
- Kinnard 10y ago>"And arguably, if you choose a language based upon its ability to help you define what is "dynamic" vs. "static" you've made some mistakes." Please elaborate.
- carterehsmith 10y ago>> We've largely decided that declarative langues (html, xaml) are better for building user interfaces. On the other hand, many of us decided the exact opposite. Check the history ?. Declarative UIs has been around for, what 30-40 years, and they don't seem to be actually gaining any share. They invariably look super-useful and productive when you build "my first app". Typically it is a "ToDo list". Then you start using it to build something larger and then you swear a lot, and eventually realize that the whole premise is flawed, and then you decide never to use declarative UIs again, ever. lol.
- Kinnard 10y agoHaha, that sounds like me. Except I more so swear a lot after developing too many apps using technology that was meant for adding hyperlinking to text documents . . .
- Kinnard 10y agoCould you recommend some alternative UIs?
- carterehsmith 10y agoAny component-based UI toolkit will fit the bill. There are many of them, as this is kind of classic approach, I would recommend React. 10 years ago, it was Sencha, DOJO, etc. As for native, every OS provides component-based UI toolkit.
- flukus 10y ago"Check the history ?. Declarative UIs has been around for, what 30-40 years, and they don't seem to be actually gaining any share." Really? Because HTML seems to be by far the most popular environment these days. many are even trying to push it to the desktop. "Then you start using it to build something larger and then you swear a lot, and eventually realize that the whole premise is flawed, and then you decide never to use declarative UIs again, ever. lol." What other abstractions are you using? If it was manipulating things based in jQuery selectors then I'd agree. But I find a combination with an MVVM framework (like knockout) it scales incredibly well.