News for hackers. Stuff that matters.
Re:“Implement text editor DOM updates manually instead of vi... by rdtsc on Thursday February 26, 2015 @11:18PM (#9117139)
That is a nice speedup!

On a funny note. My coworker called it. He said a month or so ago -- In couple of months you'll start seeing articles about "Why we moved away from React".

Wonder what's next. Maybe it wraps around back to jQuery...

Re:“Implement text editor DOM updates manually instead of vi... by rtpg on Thursday February 26, 2015 @11:45PM (#9117215)
Atom is very different from other things. The editor component is something that revolves almost entirely about state, and a huge amount of state at that.

I think the future is, like many abstractions, one where your tighter loops escape the abstraction (like numpy's C bindings). There's still advantages on a big-picture scale to using declarative frameworks like React

EDIT: one thing is that a text editor can know a lot better how to edit the DOM after an event (like hitting a character) than React's general algorithm

Re:“Implement text editor DOM updates manually instead of vi... by seanmcdirmid on Thursday February 26, 2015 @11:51PM (#9117234)
This is why I designed Glitch:

http://research.microsoft.com/apps/mobile/showpage.aspx?page...

Note that all the live editor examples in the essay are written in Glitch. Think of Glitch as a react like framework that focuses on fixing mutable state through time management rather than avoiding it.

Re:“Implement text editor DOM updates manually instead of vi... by warkid on Friday February 27, 2015 @02:44AM (#9117682)
I believe that the page you referenced to is broken. I.e. no videos or code samples on, see screenshot - http://snag.gy/lMAp8.jpg
Re:“Implement text editor DOM updates manually instead of vi... by seanmcdirmid on Friday February 27, 2015 @03:00AM (#9117736)
Re:“Implement text editor DOM updates manually instead of vi... by bglazer on Friday February 27, 2015 @10:03AM (#9119171)
Hi Sean, having skimmed the presentation you linked to, Glitch's programming model seems similar to VHDL and Verilog, in that the "tick" is an explicit construct and statements are not guaranteed to execute sequentially.

I'm not experienced in VHDL, so I might be completely wrong here.

Did you take any design cues or inspiration from hardware design languages?

Re:“Implement text editor DOM updates manually instead of vi... by seanmcdirmid on Friday February 27, 2015 @10:25AM (#9119300)
There is an inspiration from synchronous reactive languages, which are in turn inspired by hardware design (not sure if they predate or post date vhdl); you can read the related work section of the essay-linked conference paper if you are interested about lineage.

Glitch is a bit weirder in that all statements execute at the same time within a tick, their order isn't just unfixed: they are guaranteed to see all of each other's effects (except event handlers, which execute more hardware-like discretely to do state transitions).

Re:“Implement text editor DOM updates manually instead of vi... by michaelchisari on Thursday February 26, 2015 @11:48PM (#9117221)
After having watched so many frameworks come and go, the pattern I've noticed is that it's not just about hotness. It's that the new ideas that the frameworks provide push everyone else into better directions.

Everything becomes familiar. Then someone tries something new. Sometimes it works, sometimes it doesn't, sometimes it promises more than it can deliver. But all the folks who stick with familiar will take the reasons that people leave, and roll their own solutions.

Sometimes a fad framework really is a bust, but more often than not, it's always a stepping stone and motivation for every project out there.

Re:“Implement text editor DOM updates manually instead of vi... by jdub on Friday February 27, 2015 @01:03AM (#9117437)
They're using an approach that is absolutely inspired by React, for a use case that is inhospitable, pathalogical even, to a "generic web" approach to performance.

Choosing to not use React itself to implement the editing component of a text editor? Not a big deal at all.

This is not a solid "everyone moving away from React" example at all.

Re:“Implement text editor DOM updates manually instead of vi... by prapam2 on Friday February 27, 2015 @12:39AM (#9117356)
At least until something better comes along i am going with React. React makes lot easier and cleaner to build apps. I have built a stock ticker app with changing values and highlighting the change. Initially there were few performance issues, but using immutable data and shouldcomponentupdate those were resolved.
Re:“Implement text editor DOM updates manually instead of vi... by Untit1ed on Thursday February 26, 2015 @11:27PM (#9117163)
Haha, it was only a matter of time (measured in weeks) until React was over. The new hotness is evidently manually setting innerHTML.
Re:“Implement text editor DOM updates manually instead of vi... by kansface on Friday February 27, 2015 @02:12AM (#9117584)
Atom already wraps jQuery - they wrote their own DSL for mutating the DOM called space-pen[1]. They tried to get rid of it later (and rightfully so), but its too late now.

1. https://github.com/atom/space-pen

Re:“Implement text editor DOM updates manually instead of vi... by cmpb on Friday February 27, 2015 @01:18AM (#9117481)
Given the huge feature gains in vanilla JS over the past few years (and in particular, the past year via ES6), I think we'll see more people shedding frameworks altogether. At least for the common tasks that were accomplished / made simpler by jQuery.
Re:“Implement text editor DOM updates manually instead of vi... by quadratini on Thursday February 26, 2015 @11:51PM (#9117233)
He's missing the point of Declarative vs Imperative and Virtual DOM vs Data Binding if he thinks it will circle back to jQuery.
Re:“Implement text editor DOM updates manually instead of vi... by lmm on Friday February 27, 2015 @07:22AM (#9118444)
The hype cycle is a well-known, predictable thing that happens to almost every new technology.