Live data from Hacker News

Removing User Interface Complexity, or Why React is Awesome

jlongster.com

11–20 of 228 posts

Re: Removing User Interface Complexity, or Why React is Awesome

#12
post #9

Earlier quoted context omitted.

Surely this doesn't have anything to do with react though? Bower[1] or Component [2] will do this. [1] http://bower.io/ [2] http://component.io/ edit: the parent comment originally referenced a theoretical `react` command and didn't mention bower, which is why I brought it up.

Heh... was just in the process of updating my comment with Bower when you replied. I agree that this could work with Bower as the package manager. However, it would be more convenient if there was a distinction between packages that are designed to be UI components, and packages like AJAX libraries, async, and other logic libraries, which are a better fit for bower. Distributing the UI components via bower is doable,…

Not even if bower let you search by component type or some kind of category or tag?

Re: Removing User Interface Complexity, or Why React is Awesome

#13
Instead of having React altogether, wouldn't it make sense to have the browser keep track of a virtual DOM, and only repaint whatever changes on its own, while managing its own requestAnimationFrame and paint cycles?

P.S. I haven't looked into this in depth, just throwing an idea out there.

Re: Removing User Interface Complexity, or Why React is Awesome

#14
post #9

Earlier quoted context omitted.

Heh... was just in the process of updating my comment with Bower when you replied. I agree that this could work with Bower as the package manager. However, it would be more convenient if there was a distinction between packages that are designed to be UI components, and packages like AJAX libraries, async, and other logic libraries, which are a better fit for bower. Distributing the UI components via bower is doable,…

Not even if bower let you search by component type or some kind of category or tag?

The best interface for a react UI component repository would be something that had information like:

    * A picture of what the component looks like
    * How large the component is in KB
    * Which CSS frameworks it requires or supports
    * Cross browser support information
Bower is a very simple package manager right now with little information about the package beyond its name, a line of descriptive text, and a link to the Github.

Overall the experience would be better for React devs to develop a customized package manager interface well suited to the type of packages being delivered.

Of course there is nothing stopping UI component creators from distributing their components on both Bower and a React specific package manager, but I think for purposes of discoverability a React specific one would be better suited.

Re: Removing User Interface Complexity, or Why React is Awesome

#15

As a recommendation to the author, it would make sense to show the example/demo area the whole time, not only once I scroll down. It confused me. A lot.

Agreed, I really like the demo area but it's a bit of a shock when it first shows up.

Re: Removing User Interface Complexity, or Why React is Awesome

#16
For those who are only interested in the render loop, I made a library[1] around this abstraction.

I plan to expand it with a toolkit to allow thinking in terms of batches, queues and consumers, à la bacon.js[2].

[1]: https://github.com/zenoamaro/honeyloops [2]: https://github.com/baconjs/bacon.js

Re: Removing User Interface Complexity, or Why React is Awesome

#17
post #5

I really like the core concepts of React, especially the way it is designed to help you organize your code into reusable components. I think the key to making React take off is building a centralized repository for components that are open source. Then building your webapp would be as easy as importing the components you need: bower install react-navbar bower install react-signup-form bower install react-sso-signin-f…

I'm working on an app that takes this idea a step further. It is a platform that lets people create apps by defining a data schema and UI components to edit and display this. Once an app/schema/component is defined, it can be "forked" by others and further customized. Think github not for source code, but live apps[1].

One of the key requirements for this was a way to run untrusted scripts client-side (server-side is somewhat easy), since the platform lets users write arbitrary UI components. React works wonderfully here (in theory); we can isolate the React component in a sandbox (iframe with sandbox attribute set) and copy the Virtual DOM back to the main window after sanitization.

Add:

The beauty of React is that the developers recognized the limitations of other approaches; components in web apps cannot be solved with a rehash or an improvement on existing ideas. Giving up the usual design patterns and DOM hackery in favor of an esprima-based Javascript parser and serious Math is some creative thinking.

1: Open source, will have an alpha in 3 weeks: https://github.com/jeswin/fora

Re: Removing User Interface Complexity, or Why React is Awesome

#18

As a recommendation to the author, it would make sense to show the example/demo area the whole time, not only once I scroll down. It confused me. A lot.

Agreed, I really like the demo area but it's a bit of a shock when it first shows up.

Heh, it's been mixed reactions. I will probably tweak the initial experience, but will need some time because I can't leave it open on load because it blocks the header.

Re: Removing User Interface Complexity, or Why React is Awesome

#19
post #5

I really like the core concepts of React, especially the way it is designed to help you organize your code into reusable components. I think the key to making React take off is building a centralized repository for components that are open source. Then building your webapp would be as easy as importing the components you need: bower install react-navbar bower install react-signup-form bower install react-sso-signin-f…

what does React bring to the table here that Ember, Backbone, etc. don't? i could register my Backbone or Ember views with Bower all the same.

Re: Removing User Interface Complexity, or Why React is Awesome

#20
post #11

Please don't break the back button (Firefox and Chrome). In Firefox 29.0 on Ubuntu 14.04, the left sidebar with the text of the blog disappears and is replaced with a white space. I do not experience this on Chrome.

Add Opera to that list as well, or anything Blink based i would assume
Post reply on HN