Backbone Stickit with nested attributes

506 Views Asked by At

Is there a pretty way to bind and observe nested attributes (like state.city) with backbone.stickit ?

Thanks for you help.

1

There are 1 best solutions below

0
MorKadosh On BEST ANSWER

I've done that using Backbone.DeepModel (https://github.com/kahwee/backbone-deep-model). It worked just fine.

Once you've set the deep model, you can bind it's nested attributes with stickit this way:

bindings : {
"#city" : "state.city"
}