Use object.entries

This commit is contained in:
Sam Potts 2018-03-27 10:41:06 +11:00
parent 9c1bc6ab08
commit 5d079da1b8
9 changed files with 23 additions and 12 deletions

8
dist/plyr.js vendored
View File

@ -1196,8 +1196,12 @@ var utils = {
return; return;
} }
Object.keys(attributes).forEach(function (key) { Object.entries(attributes).forEach(function (_ref) {
element.setAttribute(key, attributes[key]); var _ref2 = slicedToArray(_ref, 2),
key = _ref2[0],
value = _ref2[1];
element.setAttribute(key, value);
}); });
}, },

2
dist/plyr.js.map vendored

File diff suppressed because one or more lines are too long

2
dist/plyr.min.js vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -7094,8 +7094,12 @@ var utils = {
return; return;
} }
Object.keys(attributes).forEach(function (key) { Object.entries(attributes).forEach(function (_ref) {
element.setAttribute(key, attributes[key]); var _ref2 = slicedToArray(_ref, 2),
key = _ref2[0],
value = _ref2[1];
element.setAttribute(key, value);
}); });
}, },

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -319,8 +319,11 @@ const utils = {
return; return;
} }
Object.keys(attributes).forEach(key => { Object.entries(attributes).forEach(([
element.setAttribute(key, attributes[key]); key,
value,
]) => {
element.setAttribute(key, value);
}); });
}, },