-
Notifications
You must be signed in to change notification settings - Fork 13.1k
Closed
Labels
BugA bug in TypeScriptA bug in TypeScriptFixedA PR has been merged for this issueA PR has been merged for this issue
Milestone
Description
TypeScript Version: 2.9.0-dev.20180427
Search Terms:
- definition
- javascript
Code
For the project:
base.js
module.exports = class Base {
constructor() {
console.log( "base" );
}
}foo.js
const Base = require( "./base" );
class Foo extends Base {
bar() {
const base = new Base();
const BaseClass = Base;
}
}- Run
go to definitiononBaseinnew Base()infoo
Expected behavior:
Goes to class Base in bar.js
Actual behavior:
Goes to require. If you use an import, we navigate to the class itself instead of to the import
Metadata
Metadata
Assignees
Labels
BugA bug in TypeScriptA bug in TypeScriptFixedA PR has been merged for this issueA PR has been merged for this issue