feature: remember node positions after refreshing pages
This commit is contained in:
1 parent
69a3f27cb2
commit
24ccdd47ae
5 files changed
+60
-40
No files matched your search
@@ -0,0 +1,15 @@
|
||||
export const printObject = (obj, indent = 0) => {
|
||||
const padding = ' '.repeat(indent);
|
||||
|
||||
for (const key in obj) {
|
||||
if (obj.hasOwnProperty(key)) {
|
||||
if (typeof obj[key] === 'object' && obj[key] !== null) {
|
||||
console.log(`${padding}${key}: {`);
|
||||
printObject(obj[key], indent + 2);
|
||||
console.log(`${padding}}`);
|
||||
} else {
|
||||
console.log(`${padding}${key}: ${obj[key]}`);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user