7 ms·
Ember.js - Web Applications Done Right
- sc0rb 13y agoIs Ember.js actually worth learning? Will it make me a better programmer (like learning Haskell will)? Will it enable me to get a pay rise from my current £480 per day contracting fees? Is there a more diverse and active job market than there is around my current main language (Java)? What's the point of my learning yetAnother.js? Why the down vote? I'm asking serious questions that as a professional software engineer, I worry about. The two devs next to me have expressed similar feelings when I told them about this article. Down voting me because you don't like what I said is against the HN guidelines.
- daleharvey 13y agoSome people pick technologies because they are good at solving the problems they have, not because they might help their chances at a lucrative contracting gig.
- sc0rb 13y agoNo mention of my other criteria I see. Money is an important part of a career. Weddings, houses and children cost money. So the idea is that Ember may serve to fix one particular problem in my company... I don't see how it's any better than anything else. Just because I can knock out a basic web app in less time doesn't mean it's worth learning, especially when you add learning time into the development time and compare it to the Java equivalent. Seems to me the use case (and job market) is small. I wish I was still 22 years old and didn't need to care about earning decent money...
- joachimhs 13y agoEmber.js is a framework for writing web applications on the client side. This experience, and the end result will be a lot different that the type of web apps that you might be used to writing from the server-side. I've created my share of Java-based server-side generated web applications, and when it comes to writing applications that run well on the web, JavaScript MVC frameworks are the way to go. I can't comment on how it might affect your career on either the short of long term, though. That said, I expect that the demand for these types of rich webapps will become larger as we move forward. I'm turned 22 ten years ago myself, but I think making that statement you made is unfair.
- sc0rb 13y agoSo you think that client side JS web apps are 'the way to go'. What's wrong with server side MCV web applications? How does Ember.js in the clients browser scale when you have a a lot of data that needs marshaling / unmarshaling or generally processing and moving around? Surely it's more performant to do this on the JVM on the server rather than relying on the clients computing power (or lack of). Ideally you wouldn't do a lot of data processing in the MVC part of an app anyway but it seems like you're telling me the whole web app needs to be client side?
- johnernaut 13y agoMost data-processing (if not all) should be done on the server-side. Your API should give your front-end app as much of a complete data-set as possible. Note that data 'appearance' is fine on the front-end for the most part.
- sc0rb 13y agoSo what's the point of making the MVC portion of the application client side when I can just use Spring MVC (or similar) and keep to the same tech stack that the rest of the project is using? Same goes for .NET projects etc?
- jiggy2011 13y agoIf you write all of your code to run on the server then you need to pull down a full page from the server every time you want to update your data. There's plenty of reasons you might want to avoid this in some cases. For example, you might want your forms to be validated without waiting for the user to push submit. You might have rich content in some markup language (like markdown) and you want the user to have a live preview on the same page as they are editing. Or you might have an app with real time data that changes frequently and you don't want the user to sit there pushing refresh constantly.
- sc0rb 13y ago
- bengillies 13y agoOk: > Is Ember.js actually worth learning? Yes. > Will it make me a better programmer (like learning Haskell will)? That depends on whether you've learnt the concepts that Ember introduces before or not. If you're stuck in a Java shaped rut, then yes. It will make you a better programmer. > Will it enable me to get a pay rise from my current £480 per day contracting fees? That depends whether you find someone who wants an Ember app that is willing to pay more than £480 per day. If you don't bother looking, then you're unlikely to find it. That said, if money is what you're after, there are many better avenues to go down than learning Ember or doing Java contracting. > Is there a more diverse and active job market than there is around my current main language (Java)? JavaScript is growing in popularity very quickly. If you wanted to switch to it from Java you wouldn't have any problems finding an interesting job. > So the idea is that Ember may serve to fix one particular problem in my company... I don't see how it's any better than anything else. Just because I can knock out a basic web app in less time doesn't mean it's worth learning, especially when you add learning time into the development time and compare it to the Java equivalent. You don't see how it's better because you haven't bothered learning it. By comparing it to the Java equivalent, I assume you mean GWT. In that case, yes. It's much better. Ember isn't really designed for basic web apps. It's designed for big complicated web apps. I wouldn't recommend Ember for really basic web apps at all - it imposes a lot of structure that you only really see the benefit of when your app becomes larger. > I wish I was still 22 years old and didn't need to care about earning decent money... Never wish for something out of the past. It's gone. Look to the future instead.
- sc0rb 13y agoThis feels like a pretty HN style answer. Is Ember worth learning? Let's see. It adds no value over anything that we already use or what I see being used elsewhere. It's just another library that doesn't add any significant. There is not liquid job market with good salaries or day rates with Ember at the moment, you may be able to find one or two roles in London that ask for it but it's certainly not liquid and therefore could not support a contractor. Embers approach is not radical therefore there's not a lot to learn here. I'm not stuck in a Java rut. You can write modern, slim, fast, concurrent Java. You don't have to be stuck in the days of massive J2EE government projects. The buzz around modern Java in London is massive. You're right in saying that I could do other things for money but I love software development and I love that people are willing to pay be quite large salaries and day rates to do it. My career isn't money focused but money is a part of it. Why shouldn't I have a big house and holiday often just because I love writing code? Also, seeing Java devs as being 'stuck in a rut' shows massive ignorance as to what is actually happening in the Java world right now.
- jiggy2011 13y agoThis is a bit of an odd question. Ember.js is a tool like many others. So it's sort of like asking "Will I be richer if I learn Django or if I learn Rails?". Nobody on HN can really give you a definitive answer. It is a framework for building rich javascript client web apps and helps you keep your code structured in a certain way and takes care of a great deal of boilerplate heavy lifting for you, if you take the time to learn it's idioms. So the question, "Is there a way in which I can leveridge the fact that such a framework exists in order to make more money as a consultant?" is one that only you yourself can answer.
- ekidd 13y agoMy business is based on delivering good applications very quickly. I recently delivered an Ember.js application, and my client said, "I feel like I just won the lottery." This was largely thanks to the fact that once I climbed the Ember.js learning curve, certain kinds of features became ridiculously easy to implement, and I had enough time to plow through the remaining problems with brute force. I also learned that (a) the unreleased Ember Data library is actually pretty good, but (b) getting into fights with Ember Data is catastrophic and never ends well. When Ember Data wants something specific, I fix the server to provide it and I don't argue. But no, there's no way you can go look at a job board and find Ember jobs. It's more like how I remember Rails 0.13—there's an opening for certain aggressive businesses to develop software more quickly than before, but the tools are immature and there's not really a well-established job market yet.
- meric 13y agoHow long is the Ember.js learning curve? Can you use it in an existing project? (Without replacing a large part of existing code) Asking because I might have some influence over what technologies our company might use in the near future.
- marknutter 13y agoThe down votes may be a result of people detecting loaded questions, but in the event that they are not, here's my response: > Is Ember.js actually worth learning? What's the point of my learning yetAnother.js? You're a Java developer, so it may be harder for you to understand the productivity boon that frameworks like Ember.js and Angular.js provide than it is for people who have been dealing with jQuery spaghetti code on client-side javascript apps that have become increasingly more complex as browser javascript engines have become more capable. Ember.js, Angular.js, and other frameworks that offer two-way data binding are great because they take care of the dom manipulation details developers have typically had to manage by hand in the past. It frees people up to worry more about the business logic of their javascript apps. So if you're a javascript developer sick of writing boilerplate DOM manipulation code, Ember.js is definitely worth learning. I'm partial to Angular.js because it was built with testability in mind. > Will it make me a better programmer (like learning Haskell will)? Probably not, but it will make you a more productive programmer. > Will it enable me to get a pay rise from my current £480 per day contracting fees? If you're writing Java on your main contract, probably not. This is a bizarre question anyways and probably the source of your down-votes. I personally don't look at learning a new library or language in terms of how much extra money it will make me, but instead look at how much more productive it will make me as a programmer. > Is there a more diverse and active job market than there is around my current main language (Java)? I don't know much about the Java market, but I think it's safe to say that knowing Javascript cold and keeping up with the trends in that world will make you pretty darn employable these days. Keep in mind that Ember.js and other frameworks like it are really only valuable to people who are writing single page javascript applications. If you aren't, or you are against the idea of building single-page applications, then these frameworks won't really do much for you. Although, you can still get some value out of them.
- vec 13y ago> Keep in mind that Ember.js and other frameworks like it are really only valuable to people who are writing single page javascript applications. If you aren't, or you are against the idea of building single-page applications, then these frameworks won't really do much for you. Although, you can still get some value out of them. This is fairly true of ember specifically, but much less so for some of the other frameworks. Backbone and Angular, in particular, are very well suited for building "islands of richness" in otherwise traditional sites. Even if you're doing something relatively simple, like a form with live validations and inline error messages, you're going to have an easier time writing it with something to handle the DOM manipulation for you. If you're wanting to get into frontend JS, start with Backbone. It's much less powerful than the other frameworks, but is by far the easiest to grok, and having it under your belt will give you enough tools to start moving larger and larger chunks of functionality into the browser. Come back to Ember once you outgrow that.
- tjholowaychuk 13y agoWhen you see things like Ember.Object.create() it's a clear sign to run, this isn't Java
- jops 13y agoYou're not a fan of the way Ember's doing things? I'm a js intermediate trying to get deeper into the language, so (as you're a respected js guy) if you could expand on the comment then that would be awesome. Thanks.
- jessaustin 13y agoI think the implication was rather that Java dudes would be uncomfortable working with a modern JS library, and here is one example of why. Normal people don't have to run.
- jiggy2011 13y agoObject.create() is not considered idiomatic JS rather than using the new operator.
- kilemensi 13y agoI think the correct question should be: Is it worth your time learning any of the SPA (Single Page Application) MV* JavaScript framework (Backbone, Ember, Angular, Knockout, etc). Browsers have come a long way. It's now possible to develop web applications that offer comparable user experience to say iOS/Android/Windows etc. As with those other platforms, to get the full user experience, the developer usually has to learn and use their native libraries and languages (Object-C for iOS, Java for Android, etc). For the web, the language is JavaScript and the library is HTML5 (the DOM manipulation that is). Unlike those other platforms, plain JavaScript + DOM manipulation can get out of hand pretty quickly. It works when to create 'web application' means adding a few jQuery DOM manipulations here and there, backed by your favourite server framework. But when the amount of JavaScript you have to write grows, you need a way to structure it (design patterns, modules, etc). GWT, if I remember correctly, tried to address the issue of unmanageable JavaScript by allowing you to use Java on the server side and then it will compile and serve JavaScript to the client. This seemed like a good idea but the problem still remained: You're essential writing software in one platform to run in another. There will always be a penalty somewhere (do you remember how long it took to get the first JavaServer Faces framework with HTML5 render?). The basic driving force of MV* JavaScript framework is to address the issue of writing clean, manageable and performing JavaScript code targeting the browser itself and not some intermediate platform. With the end goal being to provide a better user experience. Is this worth learning? Well, do you think applications built using client-side JavaScript provide better user experience? Think Twitter, Gmail and the likes. Do you think your clients will appreciate such kind of applications?
- nivertech 13y agoMore productive language/framework/platform will shorten your contract, so you will earn less in result.
- Morcane 13y agoWell, you ask a valid question, but the fact that you actually have to mention your current pay and are coming across as a pompous ass might cause some of the downvoting.
- pc86 13y agoI have trouble taking "[X] Done Right" articles seriously when they're posted on pages that are plastered with ads and look like the CSS hasn't be touched since 2004.
- johnernaut 13y agoAlbeit a great resource for the community to continue to produce tutorials like these on front-end frameworks, 'Web Applications Done Right' is a complete nonsense notion for what was presented. What would be hugely beneficial for beginners is someone who would take the time to go through a large-scale web app using one of these technologies. In my experience building large-scale front-end applications, I had to resort to using techniques that aren't really documented anywhere with good examples (extracting objects into presenters, decorators, dynamic template inheritance, etc...). These simple one-page apps are great as an initial learning resource - but it leaves people not understanding what they're getting themselves into later on down the road.
- joachimhs 13y agoThank you for you comments. This is one of the goals that I am trying to achieve through my book-in-progress Ember.js in Action (Manning Publications). And I do agree. Examples of large-scale applications built with any of the MVC-based frameworks is lacking.
- johnernaut 13y agoBook looks interesting - I'll have to dig into that. Thanks!
- wodow 13y agoLike a bigger TodoMVC? http://todomvc.com/ http://todomvc.com/
- apg 13y agoThat's a nice reference. Perhaps ironically, and definitely IMO, vanilla-js looks to be the simplest. Followed by jquery.
- ebiester 13y agoI have the same idea, myself. I have an idea ruminating on a better example than todomvc, but am unsure about the time commitment for the full scope of my idea. At this point, I'm thinking of doing a "stone soup" approach by putting up horrible examples of each, writing an incendiary post on HN, and relying on the outrage of the community to rewrite it properly. laughs
- Torn 13y agoFor those writing substantial client-side JS apps (rather than sprinkling jQuery here and there), a client-side MVC framework is definitely the way to go. EmberJS has however gotten a lot of flack recently regarding its docs, learning curve, and lack of API stability. The following hn link compares Angular, CanJS, Backbone and Ember: https://news.ycombinator.com/item?id=5563223 https://news.ycombinator.com/item?id=5563223 and would be a useful resource when picking a framework. We're using Backbone to write a client-side widget / look and feel library, with a bunch of Models and Views out of the box to help application developers write rich web apps. Backbone has worked out great so far, but we've had to take decisions on a fair amount of things and put the groundwork in for things like dust templates, nested views, etc. Things like Angular, CanJS, Ember, make these decisions for you and can definitely save time, if you're happy with their way of doing things. That said, we don't have View Bindings / Two-way bindings built in, we have to use Backbone Event's listenTo manually. It's worked ok for us so far, especially when you have multiple views on the same model that need to do different things when the model changes.
- johnernaut 13y agoI recently finished building a large-scale app out in Backbone. It was a joy at first - I knew I needed a flexible framework that would work with the non-conventional UI that I was to produce and Backbone worked out perfectly. After reaching 45+ models and hundreds of view files (along with custom 'controller', 'presenter' and a long chain of inheritance objects that I had to produce if I didn't want to go insane), I'm finding the app to be a bit un-manageable at this point. Another thing that's a huge pain with Backbone is it's router. The custom matching implementation for segments that was recently added is nice - but it doesn't work well at all with extremely dynamic URL's requiring tons of filtering options as query parameters (actually, there isn't any JS framework that I've seen handle that use-case well). I'm currently in the process of re-building the same app out in Ember - it's going well so far, but I have a feeling I'm going to start pulling my hair out when I get to the more complex pages.
- HarshaThota 13y ago> That said, we don't have View Bindings / Two-way bindings built in, we have to use Backbone Event's listenTo manually. It's worked ok for us so far, especially when you have multiple views on the same model that need to do different things when the model changes. Knockback.js (http://kmalakoff.github.io/knockback/ http://kmalakoff.github.io/knockback/) may help with that.
- dave_sid 13y agoEmber.js is interesting and I might even use it one day, but to suggest that web apps written in anything else are 'done wrong' is bollocks.
- joachimhs 13y agoI'm sorry you read it that way, but I do not think that I have said, nor hinted, to that at all.
- k3n 13y agoMy perception of "Web Applications Done Right" is that it implies that any other way is "wrong".
- joachimhs 13y agoWell, that perception assumes that there are only one correct solution, and that there are no grey areas... Your perception is deterministic, while mine is probabilistic.
- k3n 13y agoI'm just telling you what it comes across as, a perception that apparently I'm not the only one to hold (in fact, I wasn't going to mention it except that dave_sid had the same reaction). Defend it all you want, but that's not going to change the fact that some readers will see it as an underhanded jab.
- deleted 13y ago[deleted]
- stevewilhelm 13y agoThis example Web application isn't really "done right" until it authenticates a user and restricts photo requests based on user credentials and gracefully handles a large number of user photos (say hundreds of photos, not just ten).