8000 IE8 can't fire native events on window · Issue #115 · fat/bean · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
IE8 can't fire native events on window #115
Open
@davidmh

Description

@davidmh

I saw the same bug reported here: #32 but the fix only solves custom events.

I'm trying to do something like this:

bean.on(window, 'resize', function () { /* something */ });
// ...
bean.fire(window, 'resize');

It works great on all browsers except for IE8 (and below I guess), it throws the error: Object doesn't support this property or method, because it tries to use fireEvent from window.

Here's a testing URL: https://dl.dropboxusercontent.com/u/12380956/ie8bug/index.html

For the time being I found a workaround by using a namespace.

bean.on(window, 'resize custom.resize', function () { /* something */ });
// ...
bean.fire(window, 'custom.resize');

Plus it prevents possible issues by firing third party code binded on those events, like described on this post.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0