How will you make it if you never even try?

October 13, 2010

SproutCore Rocks, and you will be hearing about it

Filed under: ASP.NET MVC, Javascript, JQuery, SproutCore — charlieflowers @ 11:24 pm

SproutCore is an AWESOME framework for building rich internet applications in JavaScript. In a nutshell, it’s like having Cocoa inside of JavaScript (but better) … and the world is just starting to realize that is the “Right” way to be building web apps.

I have to admit, though, it sounded crazy and weird to me 2 weeks ago. But that was before I and others on my team started to be able to articulate and understand some of the problems we were running into and some opportunities for fixing them (as I described in my last post).

Look, Javascript is now a solid, reliable, powerful language for serious development. “I know,” you reply, “and that’s why I’m using JQuery and Ajax.” Right, that’s “level 1″ awareness that Javascript is now a real, reliable language. At that level, your MO is to build the same server-driven web apps we’ve been building (in Rails, ASP.NET, or whatever), but to sprinkle in some JavaScript for some “bling”.

But after you do that for a while, you may find yourself staring at “level 2″ awareness that Javascript is a real, reliable language. That’s when you say, “Hey, why don’t we build a full-blown dynamic GUI in JavaScript, that is in control of its own “flow”, that *can* choose to pull some data from a server, or send some data to a server, if and when it wants to. After all, JavaScript is a *real* language suitable for real development.”

This has been dubbed the “thin server architecture”. Your server sends and receives JSON, and does not *at all* involve itself with html or any presentation concerns. And your client doesn’t even have to follow a “page” model (although you’re likely to be running in a browser and want the back button to feel normal, so you might “map onto” a page model). Your client can be rich, and can pull great ideas from GUI toolkits such as Swing, AWT, Cocoa, etc.

And I really believe the best framework out there for doing this is SproutCore. It severely lacks documentation, but that doesn’t matter as much as you might think, because the source code for it is absolutely beautiful. It is elegant, succinct, and well-factored. That plus some of the excellent tutorials out there really put a tool of enormous power in your hands. Once you make an initial investment in deeply understanding SproutCore, I really believe you gain the kind of power that lets one person do the amount of work that previously required 10 people.

Check it out. Unfortunately, my current project just decided not to use it. It was just too weird to them. There were a lot of developers on the team who balked at learning something so “different”. What they couldn’t see was that the tool is so powerful that only 1 or 2 people would need to learn it, and our UI would simply become a “solved problem.” Oh well, I can understand … the world hasn’t yet caught up to the “level 2″ awareness that I mentioned above, and so SproutCore seems weird.

But you wait 6-12 months, and I bet you everybody and their brother will have heard of SproutCore, and more than just the “cool kids” will be using it. It is going to leave its mark on the web development world.

About these ads

10 Comments »

  1. [...] I mentioned in my last post that I believe SproutCore is far and away the best framework for building interactive web apps in Javascript. That’s true. However, JavascriptMVC is also an excellent choice, and I’m very much looking forward to working with it. [...]

    Pingback by Hello, JavascriptMVC! « The spirit of a hustler and the swagger of a college kid — October 13, 2010 @ 11:37 pm

  2. My last few experiences with sproutcore involved massive performance issues. Have these improved lately?

    Comment by modsognir — October 14, 2010 @ 5:28 pm

    • Well, I have to admit I don’t know. I looked into it as a possible choice on our current project, and loved what I discovered. But I haven’t used it on a project for an extended length of time (yet). However, a lot of people who have done so have great things to say about it.

      How long ago did you try it? Several things have been revamped over the past year, so it is possible they have improved.

      Comment by charlieflowers — October 16, 2010 @ 12:31 am

    • Modsognir,

      Where were you seeing the performance issues? SproutCore apps should be really fast. Maybe they’ve been addressed since you last worked with SC, but if they haven’t then it would be nice to know :)

      Colin

      Comment by Colin Campbell — October 17, 2010 @ 12:07 pm

  3. I admit it’s great. BUT I still cannot find a one single tutorial to make it work with ASP.NET. So I can’t really use it.
    This is also lack of documentation…

    Comment by Konstantin — October 14, 2010 @ 6:38 pm

    • Do you mean ASP.NET MVC, or WebForms? Because my current project is based on ASP.NET MVC, and I might be able to help you out there. If you mean WebForms, you might actually be the first person in the world trying that combo :) It is a strange combo, but it could make sense if you have other WebForms stuff running too.

      SproutCore “builds” down into a set of static files. You just have to serve them from a web server. There is no server-side “generation” involved at request time — the files are truly static. So you could serve those files with IIS if you want (and let IIS do authentication and stuff).

      From there, you’re just going to be making AJAX calls to the server. ASP.NET can serve those, so this should be straightforward.

      Comment by charlieflowers — October 16, 2010 @ 12:38 am

      • originally I wanted it on the WebForms (using web services) but MVC is a go as well (project is not started yet). But the real problem for me at the moment is an installation. Is there a possibility to install it just by copying some files in IIS directories, without using ruby stuff?
        Also, do I need to configure SC to use it with asp.net MVC?

        Comment by Konstantin — October 16, 2010 @ 7:17 am

      • Yes, it deploys as static files that you serve with your web server. They do recommend that you configure things to cache your application, so that the large download only has to happen once.

        And there’s no Ruby involved at deployment or runtime whatsoever.

        Comment by charlieflowers — October 17, 2010 @ 7:59 am

  4. cool, thanks! I’ll try it out.
    and are there any docs explaining how to make it talk to asp.net mvc/web services?

    Comment by Konstantin — October 17, 2010 @ 9:12 am

    • You just need to expose an action method that you can call from AJAX. Nothing more than that is required.

      Comment by charlieflowers — October 17, 2010 @ 4:24 pm


RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

The Silver is the New Black Theme. Create a free website or blog at WordPress.com.

Follow

Get every new post delivered to your Inbox.

%d bloggers like this: