Comparing version 0.0.6 to 0.0.7
@@ -31,3 +31,5 @@ "use strict"; | ||
function findExports(filePath) { | ||
const sourceFile = ts.createSourceFile(filePath, fs.readFileSync(filePath, "utf8"), ts.ScriptTarget.ES2015); | ||
const currentDir = process.cwd(); | ||
const absoluteFilePath = path.resolve(currentDir, filePath); | ||
const sourceFile = ts.createSourceFile(absoluteFilePath, fs.readFileSync(absoluteFilePath, "utf8"), ts.ScriptTarget.ES2015); | ||
const exports = []; | ||
@@ -38,3 +40,3 @@ sourceFile.forEachChild((node) => { | ||
if (moduleSpecifier && ts.isStringLiteral(moduleSpecifier)) { | ||
const importedFilePath = path.resolve(path.dirname(filePath), moduleSpecifier.text + ".ts"); | ||
const importedFilePath = path.resolve(path.dirname(absoluteFilePath), moduleSpecifier.text + ".ts"); | ||
exports.push(importedFilePath); | ||
@@ -41,0 +43,0 @@ } |
{ | ||
"name": "concat-ts", | ||
"private": false, | ||
"version": "0.0.6", | ||
"version": "0.0.7", | ||
"description": "Simple CLI tool to concats exported typescript files.", | ||
@@ -6,0 +6,0 @@ "keywords": [ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
7891
89