localvoid / uix

[UNMAINTAINED] Dart Web UI library
BSD 2-Clause "Simplified" License
77 stars 4 forks source link

Component without root element #14

Closed ranquild closed 7 years ago

ranquild commented 7 years ago

Is it possible to create component that will not have root element, but just text node? I've tried updateRoot(vText('Hello world!'));and it will not work.

localvoid commented 7 years ago

I don't remember :) I think that there is no way to do this.

I've made many mistakes working on uix, I didn't knew that returning components as root nodes is way much more important than async rendering, and I think that because of this I've made all root nodes as elements.

I've stopped working on this project long time ago, there are some things that are quite hard to do in Dart when building library like this. For example, I wanted to store element properties in something that is compiled to inline objects instead of maps, but I couldn't find any way to do this. Also, it is quite hard to bypass dart:html abstractions and work with DOM directly.