summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorCarson Gross <carson@bigsky.software>2023-12-13 15:01:16 -0700
committerCarson Gross <carson@bigsky.software>2023-12-13 15:01:16 -0700
commit73ec692e6c92b3cdab230b345944e2201c8f257c (patch)
tree8331d5f0556c5fa844935af56c068036b4bb213c
parentb75962b9bbf00f6072349fff4d0fe91baf2deb48 (diff)
downloadhtmx-73ec692e6c92b3cdab230b345944e2201c8f257c.tar.gz
htmx-73ec692e6c92b3cdab230b345944e2201c8f257c.zip
remove some `let`s that snuck in
-rw-r--r--src/htmx.js8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/htmx.js b/src/htmx.js
index c83e0246..4dcb4690 100644
--- a/src/htmx.js
+++ b/src/htmx.js
@@ -827,7 +827,7 @@ return (function () {
var oobSelects = getClosestAttributeValue(elt, "hx-select-oob");
if (oobSelects) {
var oobSelectValues = oobSelects.split(",");
- for (let i = 0; i < oobSelectValues.length; i++) {
+ for (var i = 0; i < oobSelectValues.length; i++) {
var oobSelectValue = oobSelectValues[i].split(":", 2);
var id = oobSelectValue[0].trim();
if (id.indexOf("#") === 0) {
@@ -934,7 +934,7 @@ return (function () {
function deInitOnHandlers(elt) {
var internalData = getInternalData(elt);
if (internalData.onHandlers) {
- for (let i = 0; i < internalData.onHandlers.length; i++) {
+ for (var i = 0; i < internalData.onHandlers.length; i++) {
const handlerInfo = internalData.onHandlers[i];
elt.removeEventListener(handlerInfo.event, handlerInfo.listener);
}
@@ -1979,7 +1979,7 @@ return (function () {
function countCurlies(line) {
var tokens = tokenizeString(line);
var netCurlies = 0;
- for (let i = 0; i < tokens.length; i++) {
+ for (var i = 0; i < tokens.length; i++) {
const token = tokens[i];
if (token === "{") {
netCurlies++;
@@ -2045,7 +2045,7 @@ return (function () {
var afterOnPosition = name.indexOf("-on") + 3;
var nextChar = name.slice(afterOnPosition, afterOnPosition + 1);
if (nextChar === "-" || nextChar === ":") {
- let eventName = name.slice(afterOnPosition + 1);
+ var eventName = name.slice(afterOnPosition + 1);
// if the eventName starts with a colon or dash, prepend "htmx" for shorthand support
if (startsWith(eventName, ":")) {
eventName = "htmx" + eventName