5 ms·
It's useful as long as every browser supports it. When it doesn't, and you want to polyfill, the polyfill needs to download all linked CSS files a second time,
by ZenPsycho 8y ago
It's useful as long as every browser supports it. When it doesn't, and you want to polyfill, the polyfill needs to download all linked CSS files a second time, implement a CSS parser to find the pointer-events properties, and after all that, patch in not entirely identical behaviour with javascript.
But then, this is behavior. what's it doing in a language that's supposed to be strictly about style/presentation? Why isn't it an html attribute instead?
- fouc 8y agoWould be nice to have that polyfill at the webpack build level instead of the browser. Generate css files specifically for older browsers.
- leeoniya 8y ago> It's useful as long as every browser supports it. sure, but the same can be said of every web api and other open standard with multiple implementations. https://caniuse.com/#feat=pointer-events https://caniuse.com/#feat=pointer-events > But then, this is behavior. there's not always a clean separation. what about opacity:0 and visibility: hidden? this affects intractability despite being presentation, right?
- GlitchMr 8y agoOut of curiosity, what browser do you need to support that doesn't support pointer-events? Internet Explorer 10? No longer supported by the vendor, other than for Windows Server 2012 which likely won't be used by your user. Opera Mini? What is your usecase? Opera Mini works very differently to other browsers. You can select the text whanever it's visible on the screen, even if it's covered by another element - as for this browser, the layout doesn't really exist. Disabling forms isn't as necessary, as Opera Mini waits for a script to finish once you press something.
- ZenPsycho 8y agoi did not get the memo that safari and chrome supports them now