-
Notifications
You must be signed in to change notification settings - Fork 12.8k
Remove internal uses of "namespace barrel" modules, untangle repo #51443
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Low hanging fruit for untangling: |
@jakebailey Do you mean it's better to use // @filename: core.ts
import { Debug } from "./debug";
import { __String, CharacterCodes, Queue, TextSpan, UnderscoreEscapedMap } from "./types";
import { Comparer, Comparison, EqualityComparer, MapLike, Push, SortedArray, SortedReadonlyArray } from "./corePublic";
import { isWhiteSpaceLike } from "./scanner";
.... instead of // @filename: core.ts
import {
__String, CharacterCodes, Comparer, Comparison, Debug, EqualityComparer, isWhiteSpaceLike,
MapLike, Push, Queue, SortedArray, SortedReadonlyArray, TextSpan,
UnderscoreEscapedMap,
} from "./_namespaces/ts";
... ? Or do you mean that we need to avoid |
Yes, the first one, not the last two. Reasons being:
|
In #51387, I introduced the concept of the "namespace barrel" modules, located at
**/_namespaces/*.ts
.While this does help us transition to modules, internally, this is a gross hack and makes it hard for us to start splitting the codebase up, export just the parser, etc.
We should be trying to remove internal uses of these files and use direct imports, leaving these files for our public API surface only.
The text was updated successfully, but these errors were encountered: