web: improve error handling
Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>
This commit is contained in:
@ -51,3 +51,8 @@ export function loading<T>(v: T, actual: TemplateResult): TemplateResult {
|
||||
}
|
||||
return actual;
|
||||
}
|
||||
|
||||
export function camelToSnake(key: string): string {
|
||||
var result = key.replace(/([A-Z])/g, " $1");
|
||||
return result.split(' ').join('_').toLowerCase();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user