Has anyone had any issues with backbone v0.5.1 and Jquery v1.7.2? It seems the moment I upgrade jquery from v1.5.2 to v1.7.2 my application starts behaving weirdly. The model ids don't seem to be set right and only the defaults of -1 seem to get sent to the server.
I'm not sure what are the incompatibilities between the two versions but if someone has faced this could you please point them out so that I can fix them while upgrading?
Not sure if upgrading to v0.9.2 of backbone and v1.7.2 of jquery would automagically work - would it? We can't afford to have our application broken down as of now and am a bit apprehensive of just try and see. Any suggestions?
It seems the 'illusion of incompatibility' stemmed from jQuery's treatment of the data-*
attribute tags from v1.5 to v1.7. The former ignored camelCased references e.g.
$('#myitem').data('myapp-someId')
would be evaluated as myapp-someId
but in 1.7 it converts camelCase into hyphenated separations i.e. it's evaluated as myapp-some-id
which was causing everything to break and since I didn't expect functionality to break across the two version I misconstrued it to be incompatibilities between jQuery and Backbone.
After the data-* changes and upgrading jQuery and BB to the latest version everything works fine. Phew!
Has anyone had any issues with backbone v0.5.1 and Jquery v1.7.2? It seems the moment I upgrade jquery from v1.5.2 to v1.7.2 my application starts behaving weirdly. The model ids don't seem to be set right and only the defaults of -1 seem to get sent to the server.
I'm not sure what are the incompatibilities between the two versions but if someone has faced this could you please point them out so that I can fix them while upgrading?
Not sure if upgrading to v0.9.2 of backbone and v1.7.2 of jquery would automagically work - would it? We can't afford to have our application broken down as of now and am a bit apprehensive of just try and see. Any suggestions?
It seems the 'illusion of incompatibility' stemmed from jQuery's treatment of the data-*
attribute tags from v1.5 to v1.7. The former ignored camelCased references e.g.
$('#myitem').data('myapp-someId')
would be evaluated as myapp-someId
but in 1.7 it converts camelCase into hyphenated separations i.e. it's evaluated as myapp-some-id
which was causing everything to break and since I didn't expect functionality to break across the two version I misconstrued it to be incompatibilities between jQuery and Backbone.
After the data-* changes and upgrading jQuery and BB to the latest version everything works fine. Phew!
0 commentaires:
Enregistrer un commentaire