Override SVGSVGElement method getElementById
This method may return null, but not according to the current type definitions.
Thanks for the PR!
This section of the codebase is owned by @saschanaz - if they write a comment saying "LGTM" then it will be merged.
Perhaps on this svg level this could/should return SVGElement | null because <foreignObject> should be rare enough.
I don’t think it’s a good idea to use anything other than Element | null, because that would be technically incorrect. I also doubt this would bring any benefits.
This is a spec issue, I just filed one. Thanks! https://github.com/w3c/svgwg/issues/923
Hello @saschanaz I think since your PR was merged, we can close this pr