feature(dashboard): add integrations and notifications

This commit is contained in:
Carl-Gerhard Lindesvärd
2024-10-02 22:12:05 +02:00
parent d920f6951c
commit f65a633403
94 changed files with 3692 additions and 127 deletions

View File

@@ -47,17 +47,16 @@ export function getSafeJson<T>(str: string): T | null {
export function getSuperJson<T>(str: string): T | null {
const json = getSafeJson<T>(str);
if (
typeof json === 'object' &&
json !== null &&
'json' in json &&
'meta' in json
) {
if (typeof json === 'object' && json !== null && 'json' in json) {
return superjson.parse<T>(str);
}
return json;
}
export function setSuperJson(str: Record<string, unknown>): string {
return superjson.stringify(str);
}
type AnyObject = Record<string, any>;
export function deepMergeObjects<T>(target: AnyObject, source: AnyObject): T {