Skip to content

Commit

Permalink
fix(react-doc): add ts,tsx extensions to resolver
Browse files Browse the repository at this point in the history
  • Loading branch information
Heymdall committed May 16, 2019
1 parent 2e778fa commit eda8382
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion react-doc/get-source-file-content.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ function getSourceFileContent(filePath, parentPath) {
if (path.extname(parentPath)) {
parentPath = path.dirname(parentPath);
}
filePath = resolve(filePath, { basedir: parentPath, extensions: ['.js', '.jsx'] });
filePath = resolve(filePath, { basedir: parentPath, extensions: ['.js', '.jsx', '.ts', '.tsx'] });
}
if (fs.existsSync(`${filePath}.map`)) { // if we have file with source map, read it
return {
Expand Down

0 comments on commit eda8382

Please sign in to comment.