* Existing tests showing require in ts file is not used for module resolution * Do not resolve require calls in typescript files even if it contains dynamic import Fixes #38611
13 lines
322 B
TypeScript
13 lines
322 B
TypeScript
// @traceResolution: true
|
|
|
|
// @filename: /other.ts
|
|
export const other = 123;
|
|
|
|
// @filename: /index.ts
|
|
declare const require: any;
|
|
const a: typeof import('./other') = null as any
|
|
function foo() {
|
|
const a = require('../outside-of-rootdir/foo');
|
|
const { other }: { other: string } = require('./other');
|
|
}
|