1234567891011121314151617181920212223242526 |
- import DeveloperError from "../Core/DeveloperError.js";
- function getElement(element) {
- if (typeof element === "string") {
- var foundElement = document.getElementById(element);
-
- if (foundElement === null) {
- throw new DeveloperError(
- 'Element with id "' + element + '" does not exist in the document.'
- );
- }
-
- element = foundElement;
- }
- return element;
- }
- export default getElement;
|