Skip to content

Open source website builder and Webflow alternative. Webstudio is an advanced visual builder that connects to any headless CMS, supports all CSS properties, and can be hosted anywhere, including with us.

i -> index

Roman Pominov7f12dd370fac
diff --git a/apps/designer/app/shared/tree-utils/get-instance-path.ts b/apps/designer/app/shared/tree-utils/get-instance-path.ts
index 546d571a27..9b2600c8dc 100644
--- a/apps/designer/app/shared/tree-utils/get-instance-path.ts
+++ b/apps/designer/app/shared/tree-utils/get-instance-path.ts
@@ -33,12 +33,12 @@ export const getInstancePathWithPositions = (
const find = (instance: Instance) => {
if (instance.id === instanceId) return true;
- for (let i = 0; i < instance.children.length; i++) {
- const child = instance.children[i];
+ for (let index = 0; index < instance.children.length; index++) {
+ const child = instance.children[index];
if (typeof child === "string") continue;
const found = find(child);
if (found) {
- path.push({ item: child, position: i });
+ path.push({ item: child, position: index });
return true;
}
}