-
Notifications
You must be signed in to change notification settings - Fork 1
Compatibility
Nittro doesn't really care about old browsers with crappy standards compliance etc. That being said, it is understandable that most web developers cannot in good conscience sign off 5% of the global user base. Fortunately, there are polyfills for most of what Nittro needs. This page is at the moment more of a scratch pad where I'd like to list some of the options I've come up with; work is being done on compiling a comprehensive compatibility guide that would give the developer options to choose from according to his or her needs.
Ideally, I'd like Nittro itself to deal with the absolute minimum of compatibility issues, and then provide compatibility layers separately, so that you can pick which browsers you need to support and only use the appropriate polyfills. Also if Nittro breaks, it should break gracefully and give you a means of providing the 5% of users with a working (albeit less fancy) UI instead of a broken one.
Right now Nittro will most certainly break in any IE version up to and including 9. The features missing in IE8 and below that break Nittro are:
- ES5 - Nittro needs features like
Function.prototype.bind()
andArray.prototype.indexOf()
- this can be easily fixed by including the es5-shim polyfill. - Standard event binding using the
addEventListener()
andremoveEventListener()
methods - Nittro internally only uses theUtils.DOM
utility which encapsulates a workaround for these two missing, but it's imperfect - in IE8 the Event object doesn't have atarget
property for instance - so it'd be better to use something like the ie8 polyfill by WebReflection. Also Nittro Forms need to be able to create synthetic events and that needs workarounds which this library would normalise. - Additionally, IE9 and below doesn't support the HTML5 History API, which is sort of a bummer for Nittro. There's a small polyfill called min-history by nomocas which I'd like to try out; we'll see if it's a good candidate for the job.