saloe 0.0.57 → 0.0.59

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -151,7 +151,7 @@ const listener = ({
151
151
  };
152
152
  const cloneSrcElement = ({ srcElement }) => {
153
153
  const newSrcElement = document.createElement(srcElement == null ? void 0 : srcElement.tagName);
154
- srcElement == null ? void 0 : srcElement.attributes.forEach((attr) => {
154
+ Array.from(srcElement == null ? void 0 : srcElement.attributes).forEach((attr) => {
155
155
  if (attr.startsWith("on-")) return;
156
156
  newSrcElement.setAttribute(attr.name, attr.value);
157
157
  });
@@ -149,7 +149,7 @@ const listener = ({
149
149
  };
150
150
  const cloneSrcElement = ({ srcElement }) => {
151
151
  const newSrcElement = document.createElement(srcElement == null ? void 0 : srcElement.tagName);
152
- srcElement == null ? void 0 : srcElement.attributes.forEach((attr) => {
152
+ Array.from(srcElement == null ? void 0 : srcElement.attributes).forEach((attr) => {
153
153
  if (attr.startsWith("on-")) return;
154
154
  newSrcElement.setAttribute(attr.name, attr.value);
155
155
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "saloe",
3
- "version": "0.0.57",
3
+ "version": "0.0.59",
4
4
  "description": "Tools for making web development easy and efficient",
5
5
  "type": "module",
6
6
  "scripts": {
package/src/listener.js CHANGED
@@ -217,7 +217,7 @@ const listener = ({
217
217
  const cloneSrcElement = ({ srcElement }) => {
218
218
  const newSrcElement = document.createElement(srcElement?.tagName)
219
219
 
220
- srcElement?.attributes.forEach((attr) => {
220
+ Array.from(srcElement?.attributes).forEach((attr) => {
221
221
  if (attr.startsWith('on-')) return
222
222
  newSrcElement.setAttribute(attr.name, attr.value)
223
223
  })