Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

Closed
quyin opened this issue Oct 11, 2016 · 2 comments · Fixed by microsoft/TypeScript-DOM-lib-generator#154
Labels
Bug A bug in TypeScript Domain: lib.d.ts The issue relates to the different libraries shipped with TypeScript Fixed A PR has been merged for this issue Help Wanted You can do this

Comments

@quyin
Copy link

quyin commented Oct 11, 2016

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'.
@kitsonk
Copy link
Contributor

kitsonk commented Oct 11, 2016

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

@quyin
Copy link
Author

quyin commented Oct 11, 2016

@kitsonk Thanks for the information!

@mhegazy mhegazy added Bug A bug in TypeScript Help Wanted You can do this Domain: lib.d.ts The issue relates to the different libraries shipped with TypeScript labels Oct 11, 2016
@mhegazy mhegazy added this to the Community milestone Oct 11, 2016
@mhegazy mhegazy modified the milestones: TypeScript 2.1, Community Oct 13, 2016
@mhegazy mhegazy reopened this Oct 13, 2016
@mhegazy mhegazy added Fixed in TSJS repo Fix merged in https://github.com/Microsoft/TSJS-lib-generator, but not ported yet and removed Fixed in TSJS repo labels Oct 21, 2016
@mhegazy mhegazy modified the milestones: TypeScript 2.1, TypeScript 2.1.2 Oct 27, 2016
@mhegazy mhegazy added Fixed A PR has been merged for this issue and removed Fixed in TSJS repo Fix merged in https://github.com/Microsoft/TSJS-lib-generator, but not ported yet labels Oct 31, 2016
@microsoft microsoft locked and limited conversation to collaborators Jun 19, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Bug A bug in TypeScript Domain: lib.d.ts The issue relates to the different libraries shipped with TypeScript Fixed A PR has been merged for this issue Help Wanted You can do this
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants