Files
ts-node/tests/emit-compiled.ts
Andrew BradleyandGitHub af46d2c981 #1231 followup: tslint to prettier: apply formatting changes, remove tslint:disable comments (#1251)
* results of lint-fix

* Remove tslint:disable comments

* re-run lint-fix after removing tslint:disable comments
2021-02-27 16:10:03 -05:00

17 lines
345 B
TypeScript

const extensions = ['.tsx'];
extensions.forEach((ext) => {
const old = require.extensions[ext];
require.extensions[ext] = (m, path) => {
const _compile = (m as any)._compile;
(m as any)._compile = (code, path) => {
console.error(code);
return _compile.call(this, code, path);
};
return old(m, path);
};
});