-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdiagnostic.js
More file actions
25 lines (22 loc) 路 910 Bytes
/
Copy pathdiagnostic.js
File metadata and controls
25 lines (22 loc) 路 910 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
// Quick localStorage diagnostic script
console.log("=== LOCALSTORAGE DIAGNOSTIC ===");
console.log("Raw localStorage entry:", localStorage.getItem("cruxcalc-shared-values"));
try {
const data = JSON.parse(localStorage.getItem("cruxcalc-shared-values") || "{}");
console.log("Parsed data:", data);
console.log("heightTotalInches:", data.heightTotalInches);
console.log("heightFeet:", data.heightFeet);
console.log("heightInches:", data.heightInches);
console.log("heightCm:", data.heightCm);
} catch (e) {
console.error("Failed to parse localStorage:", e);
}
// Also test SharedValues class
if (typeof SharedValues !== "undefined") {
const sv = new SharedValues();
console.log("SharedValues.load():", sv.load());
console.log("SharedValues.get('heightTotalInches'):", sv.get("heightTotalInches"));
} else {
console.log("SharedValues class not available");
}
console.log("=== END DIAGNOSTIC ===");