Skip to content

Conversation

mag123c
Copy link

@mag123c mag123c commented Sep 8, 2025

Fixes #62348

This fixes findAllReferences for the export = namespace + ES6 import pattern.

Problem

When using:

export = React;
declare namespace React { function lazy(): void; }
import { lazy } from "./mod";

Find All References doesn't work.

Solution

Added fallback symbol resolution in findAllReferences.ts for import specifiers when standard resolution fails.

Testing

Added test case findAllReferencesExportEqualsNamespace.ts. All existing tests pass

@mag123c
Copy link
Author

mag123c commented Sep 8, 2025

@microsoft-github-policy-service agree

@typescript-bot typescript-bot added the For Backlog Bug PRs that fix a backlog bug label Sep 9, 2025
Replace direct exports Map access with TypeScript's official API for more robust export= namespace + ES6 import support.
@mag123c mag123c force-pushed the fix/find-all-references-export-equals branch from abd2e2f to eb1e93f Compare September 9, 2025 06:19
@mag123c mag123c force-pushed the fix/find-all-references-export-equals branch from eb1e93f to 9beaba2 Compare September 10, 2025 08:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
For Backlog Bug PRs that fix a backlog bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Usage references can't be found for symbols exported through an exported namespace
2 participants