Skip to content

Commit 4f95977

Browse files
committedNov 1, 2023
Add fixtures around import calls access prop (#317)
1 parent 7518192 commit 4f95977

File tree

5 files changed

+14
-2
lines changed

5 files changed

+14
-2
lines changed
 
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
export const IndexComponent = () => {};
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
export const MyComponent = () => {};

‎fixtures/tsconfig-paths/index.ts

+8
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,14 @@ import * as Unknown from '@unknown';
44
import { unprefixed } from 'unprefixed';
55
import unresolved from 'unresolved/dir';
66

7+
const LazyComponent = lazy(async () => ({
8+
default: (await import('@/components/MyComponent')).MyComponent,
9+
}));
10+
11+
const IndexComponent = lazy(async () => ({
12+
default: (await import('./components/IndexComponent')).IndexComponent,
13+
}));
14+
715
a;
816
pkg;
917
unprefixed;

‎fixtures/tsconfig-paths/tsconfig.json

+2
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,9 @@
33
"exclude": ["exclude.ts"],
44
"compilerOptions": {
55
"baseUrl": ".",
6+
"types": ["node"],
67
"paths": {
8+
"@/*": ["./*"],
79
"@alias/*": ["aliased-dir/*"],
810
"@internal": ["internal-package/index.ts"],
911
"unprefixed": ["unprefixed/module.ts"]

‎test/tsconfig-paths.test.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ test('Resolve modules properly using tsconfig paths and globs', async () => {
2626
dependencies: 1,
2727
unlisted: 2,
2828
exports: 2,
29-
processed: 4,
30-
total: 4,
29+
processed: 6,
30+
total: 6,
3131
});
3232
});

0 commit comments

Comments
 (0)
Please sign in to comment.