镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content

Built-in type declaration for XMLHttpRequest is missing a readonly property 'responseURL' #11510

Description

TypeScript Version: 2.0.3

Code

let xhr = new XMLHttpRequest();
console.log(xhr.responseURL);

Expected behavior:

The compiler should be able to compile the code without errors.

Here is the MDN documentation for this property.

Actual behavior:

tsc complains:

error TS2339: Property 'responseURL' does not exist on type 'XMLHttpRequest'.

Activity

  1. kitsonk commented on Oct 11, 2016

    @kitsonk
    Contributor

    These typings come from TSJS-lib-generator where contributions are greatly welcomed.

  2. quyin commented on Oct 11, 2016

    @quyin
    Author

    Kitson Kelly (@kitsonk) Thanks for the information!

  3. added this to the milestone on Oct 11, 2016
  4. modified the milestones: TypeScript 2.1, on Oct 13, 2016
  5. modified the milestones: TypeScript 2.1, on Oct 27, 2016
  6. added
    FixedA PR has been merged for this issue
    and removed
    Fixed in TSJS repoFix merged in https://github.com/Microsoft/TSJS-lib-generator, but not ported yet
    on Oct 31, 2016
  7. locked and limited conversation to collaborators on Jun 19, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugA bug in TypeScriptDomain: lib.d.tsThe issue relates to the different libraries shipped with TypeScriptFixedA PR has been merged for this issueHelp WantedYou can do this

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions