mirror of
https://github.com/twbs/bootstrap.git
synced 2025-09-29 06:49:06 +02:00
Use template literals instead of concatenation (#33497)
This commit is contained in:
@@ -35,7 +35,7 @@ const _setElementAttributes = (selector, styleProp, callback) => {
|
||||
const actualValue = element.style[styleProp]
|
||||
const calculatedValue = window.getComputedStyle(element)[styleProp]
|
||||
Manipulator.setDataAttribute(element, styleProp, actualValue)
|
||||
element.style[styleProp] = callback(Number.parseFloat(calculatedValue)) + 'px'
|
||||
element.style[styleProp] = `${callback(Number.parseFloat(calculatedValue))}px`
|
||||
})
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user