Comparing version 4.2.0 to 4.2.1
@@ -48,5 +48,8 @@ const stripAnsi = require('strip-ansi'); | ||
function isClear(line) { | ||
function deleteClear(line) { | ||
const buffer = Buffer.from(line); | ||
return buffer.length >= 2 && buffer[0] === 0x1b && buffer[1] === 0x63; | ||
if (buffer.length >= 2 && buffer[0] === 0x1b && buffer[1] === 0x63) { | ||
return line.substr(2); | ||
} | ||
return line; | ||
} | ||
@@ -76,5 +79,5 @@ | ||
print: print, | ||
isClear: isClear, | ||
deleteClear: deleteClear, | ||
manipulate: manipulate, | ||
detectState: detectState, | ||
}; |
@@ -8,3 +8,3 @@ #!/usr/bin/env node | ||
const { extractArgs } = require('./args-manager'); | ||
const { manipulate, detectState, isClear, print } = require('./stdout-manipulator'); | ||
const { manipulate, detectState, deleteClear, print } = require('./stdout-manipulator'); | ||
const readline = require('readline'); | ||
@@ -56,4 +56,4 @@ | ||
rl.on('line', function(input) { | ||
if (noClear && isClear(input)) { | ||
return; | ||
if (noClear) { | ||
input = deleteClear(input); | ||
} | ||
@@ -60,0 +60,0 @@ |
{ | ||
"name": "tsc-watch", | ||
"version": "4.2.0", | ||
"version": "4.2.1", | ||
"description": "The TypeScript compiler with onSuccess command", | ||
"scripts": { | ||
"publish-old": "node release.js", | ||
"publish": "node release.js", | ||
"test": "mocha test/**/*.js" | ||
@@ -8,0 +8,0 @@ }, |
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
30175
537