-
Notifications
You must be signed in to change notification settings - Fork 151
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Custom event for style updates #63
Conversation
It would be great to have custom |
PR for issue #62 This is going to fail in IE10 and older, because it does not know the CustomEvent constructor. You'll need to add a polyfill for this.
what do you intend to do with it? I'd say before initializing the hacks is a good time? |
I'd like to add and remove classes to hide parts in the website that will be processed and look ugly before the buggyfill finished processing. $(window).on('viewport-units-buggyfill-init viewport-units-buggyfill-style', function (event) { if (event.type === 'viewport-units-buggyfill-init') { //add buggy class to hide something } else { //remove buggy class to hide something } }); |
Were is the best place to add the polyfill inside your core? |
since we're talking about few lines of code, I guess I'd just copy-paste it (with linking to the source) before the private functions. |
Let me test it once you merged it to the master. |
Why do you need this merged to master to test it? bower link $moduleName
npm link $moduleName |
I allready tested it with my fork, but not with the polyfill. |
I don't understand. you still need to add the polyfill to your PR anyway?! |
Lost in conversation, I thought you are going to add it. Anyway - I updated my fork. The pull request can be merged. |
feature(events): adding events `viewport-unit-buggyfill-init` and `viewport-unit-buggyfill-style`
Can be tested this way: