Compare commits
2 commits
20aa17df25
...
f37379ff8f
Author | SHA1 | Date | |
---|---|---|---|
f37379ff8f | |||
2a8823c5f7 |
1 changed files with 2 additions and 1 deletions
|
@ -225,7 +225,8 @@ export default function(filename, options = {}) {
|
|||
let program = ts.createProgram([filename], options)
|
||||
let checker = program.getTypeChecker()
|
||||
const sourceFiles = program.getSourceFiles()
|
||||
let sourceFile = sourceFiles.find(file => file.fileName === filename)
|
||||
const filenameUnix = filename.replaceAll('\\', '/')
|
||||
let sourceFile = sourceFiles.find(file => file.fileName === filenameUnix)
|
||||
|
||||
ts.forEachChild(sourceFile, visit(node, checker))
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue