You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
add ParentNode['replaceChildren'] to dom.generated.d.ts #43456
Activity
Ragzouken commentedon May 3, 2021
relevant issue from the repository the types are generated from: microsoft/TypeScript-DOM-lib-generator#985
kidlj commentedon Nov 26, 2022
Has this been merged into upstream? I have
n.parentNode.replaceChildrensuccessfully executed but TypeScript reports error:for the following code:
Also if I don't force casting
(<ParentNode>p), it reports:Don't know why.
kidlj commentedon Nov 26, 2022
Well, don't compile in production mode. I have to use type casting
(<any>p).replaceChildren(n)for it to build.jakebailey commentedon Jul 9, 2023
This was fixed back in #44684 for TS 4.4+. The examples in this thread all compile. Playground Link