Skip to content

The current types include globals that don't exist in Node #285

Description

@karfau

This is a "copy" of DefinitelyTyped/DefinitelyTyped#49953
since we copied the type definitions from DefinitlyTyped to fix the (types) regression introduced in #278.

The current types reference TypeScript's DOM typings with /// <reference lib="dom" />. This causes any module that imports xmldom to get the entire DOM typings, including globals like document.

With those globals defined we lose errors when accidentally referencing them, which can obviously cause crashes.

It'd be great if we would only provide the types that we use and export, like DOMImplementation, Document, Node, etc.

Related "main thread": #191

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinghelp-wantedExternal contributions welcomeinvalidThis doesn't seem righttypesAnything regarding Typescript

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    Status
    Done

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions