Skip to content

Commit

Permalink
fix(knowns): Support 5.5.0.
Browse files Browse the repository at this point in the history
The resolve call will find the CommonJS distribution and it won't
contain .d.ts files, so look for .js files instead.
  • Loading branch information
cartant committed Sep 23, 2017
1 parent c852b84 commit cdcad3a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions source/support/knowns.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ function read(dir: string): { [key: string]: boolean } {
const entry = resolve.sync("rxjs");
const names = fs.readdirSync(path.join(path.dirname(entry), dir));
return names
.filter((name) => /^[a-z]\w+\.d\.ts$/.test(name))
.map((name) => name.replace(/\.d\.ts$/, ""))
.filter((name) => /^[a-z]\w+\.js$/.test(name))
.map((name) => name.replace(/\.js/, ""))
.reduce((acc, name) => ({ ...acc, [name]: true }), {});
}

Expand Down

0 comments on commit cdcad3a

Please sign in to comment.