Files
ts-node/tests/throw error react tsx.tsx
Andrew BradleyandGitHub fa8e43de69 add to sourcemap tests: --transpile-only and spaces in filenames (#1329)
* add to sourcemap tests: --transpile-only and spaces in filenames

* explain why filenames have spaces so they are not removed in future refactoring

* turns out stack traces from esm uses spaces instead of %20s

* fix linter failures

* update shell invocations to quote correctly for windows

* fix
2021-05-22 18:48:17 -04:00

107 lines
585 B
TypeScript

// intentional whitespace to prove that sourcemaps are working. Throw should happen on line 100.
// 100 lines is meant to be far more space than the helper functions would take.
// Space in filename is intentional to ensure we handle this correctly when providing sourcemaps
const React = { createElement: (...args: any[]) => null };
class Foo {
constructor() {
this.bar();
}
bar() { throw new Error('this is a demo'); }
someJsx() {
return <div />;
}
}
new Foo();
export {};