feat(user-interface): introduce user interface page (#1226)

This commit is contained in:
Rıdvan Akca
2023-08-22 00:11:25 +03:00
committed by GitHub
parent 9f9ee0bb58
commit da5d594428
10 changed files with 294 additions and 42 deletions

View File

@@ -0,0 +1,18 @@
import { IJSONObject } from '@automatisch/types';
import set from 'lodash/set';
export default function nestObject<T = IJSONObject>(
config: IJSONObject | undefined
): Partial<T> {
if (!config) return {};
const result = {};
for (const key in config) {
if (Object.prototype.hasOwnProperty.call(config, key)) {
const value = config[key];
set(result, key, value);
}
}
return result;
}