Brisket – A new single-page application framework
bloomberg.com
bloomberg.com
Okay so after throwing up a bit at the hyperbole I played around with said sites. They feel fairly slow and loading different sections seems to be random how long it will take to register my click event. UX for showing page loading seems very limited and the differences in times of load for things feels very off.
Content sites like the ones Bloomberg mentions should not be done as single page webapps! The problem of rendering pages that have HTML on them has been solved - probably best to leave stuff like Brisket for apps that need it, like stock exchanges or real time analytics.
Also if its truly isomorphic, everything would still work as usual if javascript is off.
I believe you can have browser history, bookmarking, email this link any thing else you might want to do with the page in a single page application and also get the benefit of not doing a full page refresh.
Single page application are reletively new and kinks are being worked out but if I could have my cake and eat it too, I wouldn't stand in the way of those trying to make that a reality.
I had the same reaction and was confused, thinking they were going to add a bunch of real time data streams or something. After I re-read the article again, I realized they're not going to use it for something really useful to their industry.
Is this a good case for creating something where a need has already been solved a thousand times by several other frameworks?
It seems like someone watched a Haskell tutorial and copied a smart sounding word and just appended it to Javascript. This used to be called "code reuse". But that doesn't sound as cool anymore.
Huh? What's the "shape" of code?
It's not actually the "shape" that's the same, it's the HTML that it produces. It would be more accurate to call this Isohtml or Isoproduce or Isooutput apps.
People say Isomorphic when they don't know what they are saying, and want to sound smart in greek. Idiots.
The code itself is the shape of the code, to an appoximation. Isomorphic applications run the same code (or big swathes thereof) on the client and the server, so that the common core exists only in one place.
> It's not actually the "shape" that's the same, it's the HTML that it produces. It would be more accurate to call this Isohtml or Isoproduce or Isooutput apps.
A port of an application would satisfy that criteria, but would not fall under the moniker of isomorphic. If you have a better term to qualify applications with extensive to almost complete code-sharing between the client and the server, feel free to try and popularise it, but so far your demonstrations have been sorely lacking.
> People say Isomorphic when they don't know what they are saying, and want to sound smart in greek. Idiots.
Heh.
Code reuse intuitively has a much smaller scope, you can use a function on both sides it's code reuse, you can use your templates on both sides it might be (pretty advanced) code reuse. The idea behind "isomorphic" applications is that almost all of the application runs on either side of the network, it's closer to multiplatform or portable computer applications where there's a low-level substrate papering over differences and everything above that is identical.
> It seems like someone watched a Haskell tutorial and copied a smart sounding word and just appended it to Javascript.
It's not completely nonsensical though, isomorphic objects are identical on the properties used to define the morphism. The idea behind "isomorphic javascript" is that you're running (more or less) identical applications on the client and the server.
An isomorphic framework itself is effectively a proof (in the mathematical sense) of the statement: client-side rendering and server-side rendering are isomorphic.
I also agree that isomorphic is an intimidating and esoteric term. There are examples however, like the word function, which are "overly psuedo-mathy" in exactly the same way. The mapping between rendering technologies is basically an isomorphism. Each category has objects (html OR dom) and a we can map them with the html parser (html => dom). Each category has morphisms (json => html OR json => dom) and we can map them between by loading the client modules ((json => html) => (json => dom)). Finally, for some json input (J), a renderer (R) and a function (F) that performs those mappings, the framework ensures that: F(R(J)) === F(R)(J). That's not exactly an isomorphism but it's VERY similar.
Any proposals?
In 10 seconds the best alternative I've come up with is "Clerverable", as in "CLient-or-sERVER-ABLE". HEY DON'T SNICKER ALL IDEAS ARE OK IN THE BRAINSTORMING PHASE. And this term 100% solves the problem of people sounding pretentiously-smart when they say it.
(So far 'isomorphic' seems pretty secure.)
jQuery ~1.11.1 jsdom ~0.11.1 Underscore ~1.6.0 Backbone ~1.1.2 bluebird ~2.2.1 jquery-mockjax ~1.5.3 express ~4.0.0 qs 1.2.2
ಠ_ಠ
https://github.com/bloomberg/brisket
At a glance it looks unnecessarily heavy but nice to see more open sourcing.
Wikipedia states that it "is a web application or web site that fits on a single web page with the goal of providing a more fluid user experience akin to a desktop application. In an SPA, either all necessary code – HTML, JavaScript, and CSS – is retrieved with a single page load, or the appropriate resources are dynamically loaded and added to the page as necessary, usually in response to user actions." [1]
How is this any different from any other web application?
A SPA would instead only get the text of the new article and write it in place. Therefore, removing the need to re-download the entire page again. You can also read about this in the blog post by bloomberg: http://www.bloomberg.com/company/2015-03-24/bloomberg-weve-m...
Or are you making the point that anything that doesn't function this way isn't really a web application?
SPA looks more like a mobile app. As you click the links the page doesn't refresh, content just gets replaced dynamically.
Traditional web page honors web standards a bit more and looks like the traditional structure of pages linked with hyperlinks. Want to read about the product? Click a link. Want to refresh the current price? Click refresh button.
Both great with a little salt.
home.html profile.html group.html
and all of those pages are literally different views and you use ajax to grab the data.
Now you build:
index.html
with subviews and essentially index is doing all of it. Picking your subviews, handling making urls, rendering, making the requests.
I still haven't found a "class" of app that is "better" with SPAs. Just about anything you would do with an SPA you can do another way. SPAs are just the "cool new thing".
i.e. www.domain.com/user/profile/update.html can just be handled in index.html
It's my opinion this URL simplicity makes a better user experience, but that's just my opinion.
Clicks on page elements that represent some user interaction with the app should usually not trigger a whole-page reload, but instead fire some On-Click action resulting in (maybe) some data being sent to the server and (maybe) some new content being added or updated on the screen without changing the URL of the loaded page.
The client might long-poll or maintain a websocket so that new information from the server can be received without a user action. These are the types of patterns you don't normally see in "any other web app" that differentiate an "Web 2.0" SPA from "old-school Web 1.0" applications.
I would draw the distinction in navigation. Are links primarily triggering built-in browser navigation (MPA) or are they handled by long-running in-browser code, backed by asynchronous requests for additional server data (SPA)?
By contrast, single-page application (SPA) architecture holds session state in a long running in-browser Javascript application. This style is particularly strong when user actions only need to modify a portion of the screen.
It's certainly highly debatable as to whether there is any genuine benefit in presenting a text-heavy (in theory) site as a SPA. Bloomberg does the moderately clever "one article follows another article" thing, which I personally quite like but others here were fairly negative about.
It seems most sites that have speed/responsiveness/usability problems, get those problems mostly from their ads. It doesn't reflect well on the site or on the ad. I suspect it's because the metrics ad networks are using don't capture their crappy performance. I wish the original sites themselves would track ad problems and thus drive SLA compliance.
The article itself is all fluff and big claims with very little info about what's novel here. I'd expect better from a news org.
And since I live in Austin, I feel especially offended for Yankees trademarking deliciousness.