-
Notifications
You must be signed in to change notification settings - Fork 15
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
Implement Element.dataset #45
Comments
The problem with dataset is this. el.dataset.foo = "bar";
assert(el.getAttribute("data-foo") === "bar"); This basically means we need to hook |
And what about el.dataset.foo = "bar"; means that we need getter/setter, witch IE8 supported only for DOM Element :( I mean we need more stronger solution. |
You don't need getter/setters on .foo you need an ES6 proxy In theory this should work.
|
Note things like this will never work. (not without proxies) var e = document.createElement("div");
e.dataset.foo = "bar";
console.log(e.outerHTML); |
Doesn't address the issues mentioned here, but I have updated the original from Eli Grey with some improvements (including some changes taking advantage of his subsequent Xccessors shim): https://gist.github.com/4093766#file_html5_dataset.js |
I began to collect information on the possible IE8 shim.
A workaround can be found here http://eligrey.com/blog/post/html-5-dataset-support
The text was updated successfully, but these errors were encountered: