From f181f9e60de3f0d20d44864c56012c185814c584 Mon Sep 17 00:00:00 2001 From: Danny Guo Date: Sat, 7 Oct 2017 10:04:57 -0400 Subject: [PATCH] Associate .tsx files with ts-node --- lib/API/interpreter.json | 3 ++- lib/ProcessContainer.js | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/API/interpreter.json b/lib/API/interpreter.json index 8f8c373af..a36738895 100644 --- a/lib/API/interpreter.json +++ b/lib/API/interpreter.json @@ -7,5 +7,6 @@ ".js" : "node", ".coffee" : "coffee", ".ls" : "lsc", - ".ts" : "ts-node" + ".ts" : "ts-node", + ".tsx" : "ts-node" } diff --git a/lib/ProcessContainer.js b/lib/ProcessContainer.js index a1eaf815d..2b1b3f176 100644 --- a/lib/ProcessContainer.js +++ b/lib/ProcessContainer.js @@ -156,7 +156,7 @@ function exec(script, stds) { } } - if (p.extname(script) == '.ts') { + if (p.extname(script) == '.ts' || p.extname(script) == '.tsx') { try { require('ts-node/register'); } catch (e) {