documentcloud/backbone — Issue #885: Configurable window for history management
Author: alexbr
Created: 2012-01-23 17:21:40+00:00
State: open

For third-party Javascript-providers, it's useful to load the javascript in a sandboxed iframe.

For example, [LightningJS](http://lightningjs.com/) does this.

However, doing so breaks the history management, because `History` and `Router` assume they're running in the (only) window.

I've started a branch to support this, by making `history.start()` take an optional `window`-argument --- https://github.com/alexbr/backbone/compare/master...window-option

I haven't tested it in old IEs yet, and there's a Zepto-TODO, but if the approach seems okay, I'll fix that and ready a pull-request. :)