diff options
Diffstat (limited to 'js/src/dom')
-rw-r--r-- | js/src/dom/manipulator.js | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/js/src/dom/manipulator.js b/js/src/dom/manipulator.js index 04b9543c8a..faab54b5ef 100644 --- a/js/src/dom/manipulator.js +++ b/js/src/dom/manipulator.js @@ -43,16 +43,14 @@ const Manipulator = { return {} } - const attributes = { - ...element.dataset - } + const attributes = {} - Object.keys(attributes) + Object.keys(element.dataset) .filter(key => key.startsWith('bs')) .forEach(key => { let pureKey = key.replace(/^bs/, '') pureKey = pureKey.charAt(0).toLowerCase() + pureKey.slice(1, pureKey.length) - attributes[pureKey] = normalizeData(attributes[key]) + attributes[pureKey] = normalizeData(element.dataset[key]) }) return attributes |