News for hackers. Stuff that matters.
Re:Isomorphic JavaScript: The Future of Web Apps by quarterto on Monday November 11, 2013 @05:50PM (#6714666)
You keep using that word. I do not think it means what you think it means.

Using precisely defined mathematical words in contexts where they only make sense vaguely to a layperson ruins their original usage. Make up a new word. Repurpose a shitty English word. But leave our damn maths words alone.

Old man quarterto shakes his fist at you! Get off my smooth, compact lawn!

Re:Isomorphic JavaScript: The Future of Web Apps by pak on Monday November 11, 2013 @06:26PM (#6714831)
Whoa old man quarterto, who said the word ever belonged to math people in the first place? I could argue that math people have a bad habit of squeezing English words into strange contexts that corrupt the original meaning. Take "manifold" for instance, or "curl", or even something as harmless as "mode". They all meant perfectly fine things until the math people claimed them as their own.

According to M-W "isomorphic" has pre-existing definitions from medicine and chemistry that could align better with what OP is trying to say. http://www.merriam-webster.com/dictionary/isomorphic

Good day quarterto! I shall now leave to take a smooth ride in my compact car.

Re:Isomorphic JavaScript: The Future of Web Apps by williamcotton on Monday November 11, 2013 @06:56PM (#6714943)
He has a point. The system they are describing in the article isn't even isomorphic. If it WAS, it wouldn't depend on node.

To clarify, if it was a true example of isomorphism it wouldn't be contingent on a single runtime environment or language.

A better example of isomorphism in computing would be two modules of code that perform the same function and have the same abstract interface but that are written in DIFFERENT languages.

Re:Isomorphic JavaScript: The Future of Web Apps by Ygg2 on Tuesday November 12, 2013 @05:27AM (#6716935)
Iso morphism means - equal form.

According to http://en.wiktionary.org/wiki/isomorphism

one meaning is similar form. As in - server and client code have similar form.

Re:Isomorphic JavaScript: The Future of Web Apps by wrongc0ntinent on Monday November 11, 2013 @08:40PM (#6715317)
I don't see why different languages would matter. It's a matter of abstracting things from one system and having that abstracted set function in a different one. edit: To clarify, yes, the set would remain intact and functional in both systems.
Re:Isomorphic JavaScript: The Future of Web Apps by williamcotton on Monday November 11, 2013 @09:02PM (#6715401)
I've been thinking about this for the last few hours... and regardless of the language used, I think I'm finding the point of confusion!

isomorphic: modules that have the same abstract interface and functionality but that are written in different languages and executed in different runtimes

monomorphic: modules that have the same abstract interface and functionality and that are written in the same language and have the same runtime

heteromorphic: modules that have the same abstract interface and functionality and that are written in the same language but run in different runtimes

homomorphic: modules that have the same abstract interface and functionality but that are written in different langauges that run on the same runtime

See, the thing is... languages are compiled to runtimes, right? But they are transpiled to other languages...

There surface area of this discussion is very interesting and seems to have some interesting properties, and if you don't mind the math pun, it is truly a complex issue!

As for how to actually name these different things, I don't think I really mind... maybe isomorphic and monomorphic swap in the above definition... I've been reading some latin and greek roots to try and give them good names, but I'd love some suggestions!

For example, a function written in Scala that functions the same as a function written in JRuby and compiled to the JVM would be an example of a "homomorphism".

And a function written in JavaScript that is compiled to run in both node and the web browser is an example of "heteromorphism".

A function written in JavaScript that is compiled to run in the Ruby runtime is an example of "isomorphism".

Monomorphic would just be sort of like an identity property.

Also, I have no idea what I'm going on about, so please help me fix the language!

Maybe isomorphic IS the correct term for what is going on in the article, who knows? :)

Re:Isomorphic JavaScript: The Future of Web Apps by cscurmudgeon on Monday November 11, 2013 @10:31PM (#6715683)
A lot of mathematics intersects with programming. There is a clear notion of isomorphism in programming and computer science. The pedestrian web dev is not aware of it.

Imagine a graph theory researcher calling a program which handles graphs a web app. Isn't that confusing?

Re:Isomorphic JavaScript: The Future of Web Apps by drdaeman on Tuesday November 12, 2013 @07:48AM (#6717434)
In my understanding, when we're talking about formal languages (which JS is), "isomorphic" has a fairly well-defined and strict meaning.

And there's a (unsolved) conjecture that every NP-complete language are p-isomorphic: http://en.wikipedia.org/wiki/Berman%E2%80%93Hartmanis_conjec...

Re:Isomorphic JavaScript: The Future of Web Apps by pmelendez on Tuesday November 12, 2013 @09:36AM (#6718017)
>"According to M-W "isomorphic" has pre-existing definitions from medicine and chemistry"

That link doesn't say that those definitions were "pre-existing". They say the first use was on 1862 but failed in specifying in which context was used first.

Re:Isomorphic JavaScript: The Future of Web Apps by guerrilla on Monday November 11, 2013 @06:09PM (#6714741)
Amen! I'm glad someone said something. That really bothered me. It's actually the only reason I clicked on the link. In my head, they'd somehow mapped Javascript onto another language and were able to convert interchangeably between the two or something like that. Needless to say, I was disappointed.
Re:Isomorphic JavaScript: The Future of Web Apps by natural219 on Monday November 11, 2013 @09:57PM (#6715576)
I can't disagree more. From thefreedictionary.com:

  (Mathematics) A one-to-one correspondence between the elements of two sets such 
  that the result of an operation on elements of one set corresponds to the result
  of the analogous operation on their images in the other set.
This seems exactly like what the author is describing. Colloquial English does not have an objective standard -- it is a constantly evolving language. I certainly agree with this term's usage unless a better one is suggested.
Re:Isomorphic JavaScript: The Future of Web Apps by millstone on Tuesday November 12, 2013 @04:42AM (#6716766)
But notice that the isomorphism is the correspondence itself. When you read "isomorphic JavaScript," you would be right to ask "isomorphic to what?" What is JavaScript in correspondence to?

If there is an isomorphism here, it is between the separate runtimes (client and server), and not the language.

Re:Isomorphic JavaScript: The Future of Web Apps by frontendbeauty on Monday November 11, 2013 @07:25PM (#6715065)
(author here) Good point. TBH, I have no idea what "isomorphic" means in the mathematical sense.

I was inspired to use "isomorphic" from a 2011 article by Nodejitsu [1]. It seemed like a fine way to describe this approach. I would gladly use a better would if I were to find one.

[1] http://blog.nodejitsu.com/scaling-isomorphic-javascript-code

Re:Isomorphic JavaScript: The Future of Web Apps by williamcotton on Monday November 11, 2013 @07:27PM (#6715072)
How about "monomorphic", having or existing in only one form?
Re:Isomorphic JavaScript: The Future of Web Apps by wrongc0ntinent on Monday November 11, 2013 @08:48PM (#6715337)
Technically, you're correct, see the biology and chemistry use of the word. But seeing how you're dealing with a mathematically inclined audience, there will be disapproval. I think it's a very useful concept in general, the more it gets out into the world, the better.
Re:Isomorphic JavaScript: The Future of Web Apps by btilly on Tuesday November 12, 2013 @03:08AM (#6716446)
I like relocatable JavaScript.
Re:Isomorphic JavaScript: The Future of Web Apps by yuchi on Tuesday November 12, 2013 @04:18AM (#6716682)
It's the first time that I hear about it, and I do not dislike relocatable at all
Re:Isomorphic JavaScript: The Future of Web Apps by spikels on Tuesday November 12, 2013 @01:52PM (#6719959)
There are only two hard things in Computer Science: cache invalidation and naming things.

A few ideas:

"End-to-End JavaScript" - popular but not exactly what you mean but close

"Run Anywhere JavaScript"

"Write Once JavaScript"

"Two Sided JavaScript" - server-side and browser-side

"Browse-N-Serve Javascript"

Re:Isomorphic JavaScript: The Future of Web Apps by poissonpie on Tuesday November 12, 2013 @03:44AM (#6716561)
What about simply DRY? isn't that what you're aiming for - having code sharable between client and server such that you don't have two pieces of code that do the same thing in two different places?
Re:Isomorphic JavaScript: The Future of Web Apps by bpizzi on Tuesday November 12, 2013 @06:58AM (#6717230)
Shall "multiplateform javascript [code]" be suitable here? Looks like this is all it's about: having a single js code generating the same results, with no dependance on the plateform.
Re:Isomorphic JavaScript: The Future of Web Apps by frontendbeauty on Tuesday November 12, 2013 @01:17PM (#6719610)
I like "multiplatform" -- current winner :)
Re:Isomorphic JavaScript: The Future of Web Apps by drdaeman on Tuesday November 12, 2013 @07:42AM (#6717410)
> I have no idea what "isomorphic" means in the mathematical sense.

Programmers these days!...

Re:Isomorphic JavaScript: The Future of Web Apps by ot on Tuesday November 12, 2013 @04:24AM (#6716711)
I agree. Even if not precisely defined, isomorphic usually refers to things that are (possibly) different, but "look the same" under a particular lens (for example, a set of operations).

OTOH, this is talking about the same thing running in two different contexts. More appropriate terms might be uniform, homogeneous, ...

Re:Isomorphic JavaScript: The Future of Web Apps by acjohnson55 on Monday November 11, 2013 @06:14PM (#6714761)
Agreed. I like "Nomadic JavaScript" better! Or "Unbound JavaScript". Or "Bicoastal JavaScript". Or maybe "Freebased JavaScript". Anything else.
Re:Isomorphic JavaScript: The Future of Web Apps by danabramov on Tuesday November 12, 2013 @08:15AM (#6717570)
Freewheelin' JavaScript
Re:Isomorphic JavaScript: The Future of Web Apps by wrongc0ntinent on Monday November 11, 2013 @08:32PM (#6715298)
Actually mathematics got it from chemistry: http://en.wikipedia.org/wiki/Eilhard_Mitscherlich

Before maths, it was probably mostly geologists that used it. It's also used plenty in evolutionary biology, but this was probably after maths (not sure though).

Re:Isomorphic JavaScript: The Future of Web Apps by Ygg2 on Tuesday November 12, 2013 @05:26AM (#6716931)
Actually isomorphism only means, similar form. And it makes sense in the context - as in server and client code have similar form.

The fact that it's used in math is incidental. It's used in biology and chemistry as well. It does leave space for ambiguity because of closeness of math and computer science, but overall it's correct usage.

Re:Isomorphic JavaScript: The Future of Web Apps by BUGHUNTER on Tuesday November 12, 2013 @07:53AM (#6717454)
I wish I could filter out totally uninteresting threads in HN website that are disturbing my reading experience - is there any CSS hack / tool that adds a "don´t show this thread" button to HN discussion threads?
Re:Isomorphic JavaScript: The Future of Web Apps by siegecraft on Monday November 11, 2013 @06:05PM (#6714728)
I just assumed it meant the opposite of polymorphic, but no it's not even related to that..
Re:Isomorphic JavaScript: The Future of Web Apps by mkehrt on Monday November 11, 2013 @06:57PM (#6714948)
That's "monomorphic". Really!
Re:Isomorphic JavaScript: The Future of Web Apps by gsg on Tuesday November 12, 2013 @01:32AM (#6716225)
It is related, really.

Polymorphic: many shaped. Monomorphic: single shaped. Isomorphic: same shaped.

Re:Isomorphic JavaScript: The Future of Web Apps by vbuterin on Tuesday November 12, 2013 @07:57AM (#6717473)
I think it might be some kind of parody on "angular".
Re:Isomorphic JavaScript: The Future of Web Apps by the1 on Monday November 11, 2013 @08:16PM (#6715250)
isomorph(ism) is actually from chemistry, not mathematics.
Re:Isomorphic JavaScript: The Future of Web Apps by dllthomas on Monday November 11, 2013 @08:36PM (#6715310)
It's from Greek, really. It's used in both chemistry and mathematics.

http://mathworld.wolfram.com/Isomorphism.html

Re:Isomorphic JavaScript: The Future of Web Apps by enraged_camel on Monday November 11, 2013 @08:32PM (#6715299)
But in the end, isn't everything math?

longingly gazes into the distance

Re:Isomorphic JavaScript: The Future of Web Apps by Ygg2 on Tuesday November 12, 2013 @05:29AM (#6716941)
No.

longingly gazes into the dead stars