Commit 8be5334

Anton Golub <mailbox@antongolub.ru>
2021-05-25 21:21:50
fix: use typesctipt tsc bin instead of deprecated tsc pkg (#117)
Co-authored-by: Anton Medvedev <antonmedv@google.com>
1 parent 2411c37
Changed files (1)
zx.mjs
@@ -117,7 +117,7 @@ async function importPath(filepath, origin = filepath) {
   if (ext === '.ts') {
     let {dir, name} = parse(filepath)
     let outFile = join(dir, name + '.mjs')
-    await run`npm_config_yes=true npx tsc --target esnext --module esnext --moduleResolution node ${filepath}`
+    await run`npm_config_yes=true npx -p typescript tsc --target esnext --module esnext --moduleResolution node ${filepath}`
     await fs.rename(join(dir, name + '.js'), outFile)
     let wait = importPath(outFile, filepath)
     await fs.rm(outFile)