Getting Into Ember.js Getting Into Ember.js / tutorial / free

http://net.tutsplus.com/tutorials/javascript-aj...

With a curiously lacking quickstart guide on Ember.js homepage, here is a brief tutorial to get you started with the foundation setup.
0 favorites
submitted over 3 years ago, by pineapple
Getting Into Ember.js popular tutorial

11 Comments

pineapple
lush

Thanks, this Peep Code screencast is pretty good too:-

https://peepcode.com/products/emberjs

lush, over 3 years ago

pineapple

I almost bought that, but I went with angularjs instead. I like not depending on JQ and i liked the way it handles stuff a bit more. Going with a JS framework on my new app has definitely changed how I feel about spaghetti JS code.. it's literally a paradigm shift in my thinking about JS

pineapple, over 3 years ago

lush

I bought it, it's a good visual demonstration on how to get into Ember for me. Although Backbone has greater performance apparently so:-

http://jsfiddle.net/krisselden/bYPPT/

lush, over 3 years ago

pineapple

How do you like ember so far? I love all the drama on HN news today about ember

popcorn

pineapple, over 3 years ago

lush

Only done drips and drabs with it at the moment but hoping to use it in a new project. What about you? So far, Angular seems like the easiest to understand for me.

lush, over 3 years ago

pineapple

I'm REALLY loving angular. I'm trying to figure out nested forms with it and no one has any help or input, but aside from that I'm really digging it. I can say I wont be using jquery again, at least not how I have been this whole time.

pineapple, over 3 years ago

lush

Too far down the tree to reply to your last comment. Are you trying to accomplish a multi-part form triggered via front-end JS?

lush, over 3 years ago

pineapple

I have a rails form that accepts a huge amount of fields and fields_for. This is somewhat confusing with angular because I would need to write some quite cluttered and long method to parse the fields_for and make that something so angular could understand as a template. Just seems dirty to me. I could also use $resource but if I started sending requests for all the fields that seems like a lot of requests for something that can be handled in 1.

Ryan did something similar here:

module ApplicationHelper
  def link_to_add_fields(name, f, association)
    new_object = f.object.send(association).klass.new
    id = new_object.object_id
    fields = f.fields_for(association, new_object, child_index: id) do |builder|
      render(association.to_s.singularize + "_fields", f: builder)
    end
    link_to(name, '#', class: "add_fields", data: {id: id, fields: fields.gsub("\n", "")})
  end
end

That uses link_to but you get idea.

All I have is a form, and inside of that I have a text area that is inside a <div ng-form>. I want the text field to add to a model when you hit enter, as opposed to submitting the outer form. The only thing at this point that I can think of is to just make a keypress binding for the enter key.

pineapple, over 3 years ago

SkinnyGeek1010

Hehe, yea it get's pretty good sometimes.

I tried ember and I can't wrap my head around how they proxy the models to the controllers..... wat. A lot of people like it though.

SkinnyGeek1010, over 3 years ago

lush

lush, over 3 years ago


Login or to comment.

Tutorials are any resources you learn from.

Examples: an intro to html5 screencast, a pdf about git, photoshop effects tutorials, meta-programming in ruby, lambda calculus, higher-order fixed-point combinators.

Tools are websites, apps or services used -on- your project (indirectly), to aid the process.

Examples: A color scheme generator, email marketing software, usability heat maps, css3 code generators, a downloadable png compressor.

Assets are downloadable files used -in- your projects, usually as code, textures, or images.

Examples: a jquery sticky menu, photoshop brushes, background textures, mvc frameworks, twitter bootstrap, 960 grid system.