Adding LayoutManager to position videos as cleverly as possible
This commit is contained in:
parent
4b940a571c
commit
7232bbaef9
3 changed files with 105 additions and 1 deletions
10
front/src/WebRtc/HtmlUtils.ts
Normal file
10
front/src/WebRtc/HtmlUtils.ts
Normal file
|
@ -0,0 +1,10 @@
|
|||
export class HtmlUtils {
|
||||
public static getElementByIdOrFail<T extends HTMLElement>(id: string): T {
|
||||
const elem = document.getElementById(id);
|
||||
if (elem === null) {
|
||||
throw new Error("Cannot find HTML element with id '"+id+"'");
|
||||
}
|
||||
// FIXME: does not check the type of the returned type
|
||||
return elem as T;
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue