Skip to content

Commit

Permalink
Refactor translate.js
Browse files Browse the repository at this point in the history
The variable has not been reassigned a value, so it's better to use "const" instead of "let", to prevent any unexpected behavior that may occur due to unintended assignment.
  • Loading branch information
ahmed0saber committed Jul 15, 2023
1 parent fc95edd commit 6fc9189
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/translate.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ export default function (Glide, Components, Events) {
* @return {Void}
*/
set (value) {
let transform = mutator(Glide, Components).mutate(value)
const transform = mutator(Glide, Components).mutate(value)
const translate3d = `translate3d(${-1 * transform}px, 0px, 0px)`

Components.Html.wrapper.style.mozTransform = translate3d // needed for supported Firefox 10-15
Expand Down

0 comments on commit 6fc9189

Please sign in to comment.