Skip to content

Tag: backbone-events

How to catch form submit with Backbone.js

When I test and click my apply button after I put in data in my input fields, I get a file not found error. The Login button is a dummy button with no functionality to it. I want to only display an alert box that says “You logged in as (user name here) Succesfully!!!” after apply is clicked. Answe…

Custom mouse events in backbonejs

What would be a good way of supporting custom mouse events? For example, I currently have: But instead of mousedown, I would like to create a custom event called mousedrag which would be a combination of mousedown and mousemove. Is there any recommended way of adding such a custom event? Answer Since Backbone…

Backbone and jQuery events

I have a simple task – retrieve click listener function from DOM element. I’ve fased two problems: I have no idea how to obtain event listener, that was set via addEventListener function $(element).data(‘events’) is always empty Talking about first problem – I think it’s no…

Backbone View events not firing

I am using Rails3 as my backend and Jammit to asset… Now I am trying to not compress and even package the assets. The simple event don’t get run, but the alert(‘asd’) int initialize is working as expected. I have already tried other kinds of events in other objects too, but it didn&#82…