davatron5000 / FitText.js

A jQuery plugin for inflating web type
http://fittextjs.com
6.76k stars 1.39k forks source link

JQuery 1.4.2 and FitText fails to update text size on orientation change... #67

Closed tyrauber closed 11 years ago

tyrauber commented 11 years ago

.... $(window).on causes FitText to throw the js error: "TypeError: 'undefined' is not a function (evaluating '$(window).on('resize.fittext orientationchange.fittext', resizer)')". $(window).bind does not and is compatible with jQuery 1.0/

davatron5000 commented 11 years ago

jQuery 1.4.2 is over 3 years old. I think we're going to prefer on() as it's recommended by jQuery.

As of jQuery 1.7, the .on() method is the preferred method for attaching event handlers to a document

http://api.jquery.com/bind/