News for hackers. Stuff that matters.
Re:An Introduction to Reactive Programming by CmonDev on Monday June 30, 2014 @10:18AM (#7965135)
"Javascript is the most familiar language out there at the moment"

Will people ever stop using this reasoning? Why not pick the best/better language instead?

Re:An Introduction to Reactive Programming by jrajav on Monday June 30, 2014 @10:26AM (#7965179)
Because the goal here is not to write the most efficient and most maintainable code, but to demonstrate a new concept. Familiarity and availability are more relevant in this case than "best language," however you'd measure that.
Re:An Introduction to Reactive Programming by derefr on Monday June 30, 2014 @12:18PM (#7965856)
Hmm. Java might be known by more, if just from the fact that those who take an introductory CS course as an elective in another major will get their lessons in it. But, as a lingua franca, it sucks even worse.

Mind that term, actually: while French itself was just an average European language, it was handy, for political reasons, for diplomats of all stripes to pick up—and somewhat easy, presuming you had studied texts in Latin. JS is much the same: a lot of us might not prefer it when writing our own code, but we can all certainly read it, given its ALGOL derivation, and it's certainly more pithy than, say, C, for communicating the kind of concepts we need to communicate (like FRP.)

Re:An Introduction to Reactive Programming by Terr_ on Monday June 30, 2014 @07:32PM (#7968325)
> But, as a lingua franca, it sucks even worse. Mind that term, actually: while French itself [...]

Mind that term even more, because despite the similar "fr--" sound, it does not actually denote the French language.

"Lingua franca" is actually an Italian term for "Frankish language", during a time (post-middle-ages) when "Franks" often referred to Western Europe in general.

While French is an example of a language which fit the definition for a period of time, it is not the source of its name.

Re:An Introduction to Reactive Programming by avmich on Monday June 30, 2014 @10:26AM (#7965184)
There is a lot of sense in it.

First, most everybody has a JS engine handy, right in the browser of his choice. JS is reasonably standardized - the subset of it which is common between all browsers is pretty big. Then, JS is rather well known, since all web development has to include that - and that's a sizeable part of all development. Next, the language itself isn't that bad - you may write procedural, object-oriented or functional code relatively easy. Even better, the implementations are quite good lately, being forced to evolve under the pressure of demand.

Can you name a language which would best JavaScript in all these points?

Re:An Introduction to Reactive Programming by rimantas on Monday June 30, 2014 @01:54PM (#7966470)

  > Can you name a language which would best JavaScript in
  > all these points?
Why language has to best javascript in all these points? What's the point? Why should I want to write procedural, object oriented or functional code in the same language? Why not choose a language that fits a task at hand instead of being "quite good" or maybe "not that bad" and "rather well known"? Javascript for everything is at the same level of moronism (and subset of) webtech for everything. It just does not make any sense.
Re:An Introduction to Reactive Programming by gnerd on Monday June 30, 2014 @02:43PM (#7966761)
Well I think in this case the language does fit the task at hand, since the language choice is one of communication (communicating concepts), it's probably a wise choice to go with a ubiquitous one to achieve the goal of delivering a message to the widest possible audience with the least friction possible.

I don't know if English is better or worse than Lithuanian, but none of that probably factored into your decision to speak English here rather than your mother tongue. Like many of the other non-English speakers I see on HN, I don't assume you are saying English is a superior language, rather I assume it is that you see as English is the lingua-fanca of the world currently, you want to lower barriers to understanding your concepts and communicate to the widest audience possible. If that is why they chose JavaScript, then to me, that's a rational choice.

Re:An Introduction to Reactive Programming by X4 on Monday June 30, 2014 @03:56PM (#7967277)
Then this paper might be of great help to you

http://lampwww.epfl.ch/~imaier/pub/DeprecatingObserversTR201...

It's straightly viewn from an implementor's perspective in my opinion.

Tl:Dr.: The observer-pattern is bad and encourages callback-hell, therefore a Data-Flow DSL is implemented to control the order of evaluation. It's kind of showing the implementation of an IO-Monad.

Re:An Introduction to Reactive Programming by aikah on Monday June 30, 2014 @11:44AM (#7965625)
He is right.Everybody has a browser, where one cast copy paste code ,execute it and see the result.

Not sure what the alternative would be.Python/C/C++ on linux maybe.

But on Windows? what language does Windows support from scratch that Linux supports?

And since everybody knows Javascript... Not saying I like the language but it became easy to explain something in a language everybody can read through js.

Re:An Introduction to Reactive Programming by mattpodwysocki on Monday June 30, 2014 @11:45AM (#7965635)
Because in this case, RxJS is actually quite easy to explain because of the lack of generics and angle brackets to get in your way to explain concepts. (Speaking as the author of RxJS).

That and it's very applicable to current problems with web-based programming of the coordination of events, promises, and any other I/O such as Web Sockets, XHRs, etc.

Re:An Introduction to Reactive Programming by Keyframe on Monday June 30, 2014 @10:39AM (#7965254)
It's BASIC of new generation(s).
Re:An Introduction to Reactive Programming by yzzxy on Monday June 30, 2014 @09:51PM (#7968788)
So what is its GOTO?
Re:An Introduction to Reactive Programming by thrantal on Tuesday July 01, 2014 @01:57AM (#7969314)
In Bacon.js it's the Bus. I'm not sure if RxJs yet has such thing :)
Re:An Introduction to Reactive Programming by collyw on Monday June 30, 2014 @10:26AM (#7965181)
Agreed.