Home
last modified time | relevance | path

Searched refs:importClause (Results 1 – 25 of 39) sorted by relevance

12

/third_party/typescript/src/services/codefixes/
DsplitTypeOnlyImport.ts29 const importClause = Debug.checkDefined(importDeclaration.importClause); constant
34 …factory.updateImportClause(importClause, importClause.isTypeOnly, importClause.name, /*namedBindin…
40 …factory.updateImportClause(importClause, importClause.isTypeOnly, /*name*/ undefined, importClause
DconvertToTypeOnlyImport.ts30 if (!importDeclaration?.importClause) {
34 const { importClause } = importDeclaration; constant
39 if (importClause.name && importClause.namedBindings) {
40 …ges.deleteNodeRangeExcludingEnd(context.sourceFile, importClause.name, importDeclaration.importCla…
47 importClause.name,
DimportFixes.ts338 … const namespaceImport = tryCast(declaration.importClause?.namedBindings, isNamespaceImport);
352 … return tryCast(declaration.importClause?.namedBindings, isNamespaceImport)?.name.text;
366 const { importClause } = declaration; constant
367 if (!importClause) return undefined;
368 const { name, namedBindings } = importClause;
370 …? { kind: ImportFixKind.AddToExisting, importClauseOrBindingPattern: importClause, importKind, mod…
/third_party/typescript/src/services/
DorganizeImports.ts95 const { importClause, moduleSpecifier } = importDecl; constant
97 if (!importClause) {
103 let { name, namedBindings } = importClause;
198 …DeclarationAndClause(defaultImport, defaultImport.importClause!.name, namespaceImports[0].importCl…
204 …compareIdentifiers((i1.importClause!.namedBindings as NamespaceImport).name, (i2.importClause!.nam…
209 …arationAndClause(namespaceImport, /*name*/ undefined, namespaceImport.importClause!.namedBindings)…
219 newDefaultImport = defaultImports[0].importClause!.name;
224 …ateImportSpecifier(factory.createIdentifier("default"), defaultImport.importClause!.name!)); // TO…
228 …newImportSpecifiers.push(...flatMap(namedImports, i => (i.importClause!.namedBindings as NamedImpo…
242 …: factory.updateNamedImports(namedImports[0].importClause!.namedBindings as NamedImports, sortedIm…
[all …]
DsuggestionDiagnostics.ts93 const { importClause, moduleSpecifier } = node; constant
94 …return importClause && !importClause.name && importClause.namedBindings && importClause.namedBindi…
95 ? importClause.namedBindings.name
Dutilities.ts821 if (node.importClause) {
822 if (node.importClause.name && node.importClause.namedBindings) {
829 if (node.importClause.name) {
830 return node.importClause.name;
839 if (node.importClause.namedBindings) {
840 if (isNamedImports(node.importClause.namedBindings)) {
842 const onlyBinding = singleOrUndefined(node.importClause.namedBindings.elements);
848 else if (isNamespaceImport(node.importClause.namedBindings)) {
849 return node.importClause.namedBindings.name;
1984 …export function getTypeKeywordOfTypeOnlyImport(importClause: ImportClause, sourceFile: SourceFile)…
[all …]
DnavigationBar.ts240 const importClause = <ImportClause>node; constant
243 if (importClause.name) {
244 addLeafNode(importClause.name);
250 const { namedBindings } = importClause;
Dservices.ts822 const importClause = (<ImportDeclaration>node).importClause; constant
823 if (importClause) {
826 if (importClause.name) {
827 addDeclaration(importClause.name);
833 if (importClause.namedBindings) {
834 … if (importClause.namedBindings.kind === SyntaxKind.NamespaceImport) {
835 addDeclaration(importClause.namedBindings);
838 forEach(importClause.namedBindings.elements, visit);
DtextChanges.ts1378 …function deleteDefaultImport(changes: ChangeTracker, sourceFile: SourceFile, importClause: ImportC…
1379 if (!importClause.namedBindings) {
1381 deleteNode(changes, sourceFile, importClause.parent);
1385 const start = importClause.name!.getStart(sourceFile);
1386 const nextToken = getTokenAtPosition(sourceFile, importClause.name!.end);
1393 deleteNode(changes, sourceFile, importClause.name!);
DimportTracker.ts264 …const { name, namedBindings } = decl.importClause || { name: undefined, namedBindings: undefined };
/third_party/jsframework/mock-generate/src/declaration-node/
DimportAndExportDeclaration.ts68 const importClause = importNode.importClause; constant
69 if (importClause !== undefined) {
70 …importElements = sourceFile.text.substring(importClause.pos, importClause.end).trimStart().trimEnd…
/third_party/typescript/src/services/refactors/
DconvertImport.ts60 const { importClause } = importDecl; constant
61 if (!importClause) {
65 if (!importClause.namedBindings) {
69 return importClause.namedBindings;
DmoveToNewFile.ts212 …return node.importClause && node.importClause.namedBindings && node.importClause.namedBindings.kin…
213 node.importClause.namedBindings.name : undefined;
371 if (!importDecl.importClause) return;
372 const { name, namedBindings } = importDecl.importClause;
387 importDecl.importClause,
388 …factory.updateImportClause(importDecl.importClause, importDecl.importClause.isTypeOnly, name, /*na…
586 const clause = i.importClause;
/third_party/typescript/src/compiler/transformers/
Dutilities.ts48 const bindings = node.importClause && node.importClause.namedBindings;
65 …ort(node) || (!!node.importClause && isNamedImports(node.importClause.namedBindings!) && containsD…
Ddeclarations.ts713 if (!decl.importClause) {
719 decl.importClause,
724 …efaultBinding = decl.importClause && decl.importClause.name && resolver.isDeclarationVisible(decl.
725 if (!decl.importClause.namedBindings) {
728 decl.importClause,
729 decl.importClause.isTypeOnly,
734 if (decl.importClause.namedBindings.kind === SyntaxKind.NamespaceImport) {
736 …t namedBindings = resolver.isDeclarationVisible(decl.importClause.namedBindings) ? decl.importClau…
738 decl.importClause,
739 decl.importClause.isTypeOnly,
[all …]
Dts.ts2810 if (!node.importClause) {
2815 if (node.importClause.isTypeOnly) {
2821 const importClause = visitNode(node.importClause, visitImportClause, isImportClause); constant
2822 return importClause ||
2829 importClause,
/third_party/typescript/src/compiler/transformers/module/
Dsystem.ts457 if (!entry.importClause) {
595 if (node.importClause) {
943 const importClause = decl.importClause; constant
944 if (!importClause) {
948 if (importClause.name) {
949 statements = appendExportsOfDeclaration(statements, importClause);
952 const namedBindings = importClause.namedBindings;
Dmodule.ts798 if (!node.importClause) {
1394 const importClause = decl.importClause; constant
1395 if (!importClause) {
1399 if (importClause.name) {
1400 statements = appendExportsOfDeclaration(statements, importClause);
1403 const namedBindings = importClause.namedBindings;
/third_party/typescript_eslint/packages/typescript-estree/src/
Dconvert.ts1598 if (node.importClause) {
1599 if (node.importClause.isTypeOnly) {
1603 if (node.importClause.name) {
1604 result.specifiers.push(this.convertChild(node.importClause));
1607 if (node.importClause.namedBindings) {
1608 switch (node.importClause.namedBindings.kind) {
1611 this.convertChild(node.importClause.namedBindings),
1616 node.importClause.namedBindings.elements.map(el =>
/third_party/typescript/src/testRunner/unittests/services/
DorganizeImports.ts985 assertEqual(decl1.importClause, decl2.importClause);
/third_party/typescript/src/compiler/factory/
DnodeFactory.ts3934 importClause: ImportClause | undefined,
3942 node.importClause = importClause;
3945 propagateChildFlags(node.importClause) |
3956 importClause: ImportClause | undefined,
3961 || node.importClause !== importClause
3963 … ? update(createImportDeclaration(decorators, modifiers, importClause, moduleSpecifier), node)
5922 …ode) ? updateImportDeclaration(node, node.decorators, modifiers, node.importClause, node.moduleSpe…
Dutilities.ts497 if (node.kind === SyntaxKind.ImportDeclaration && node.importClause) {
/third_party/typescript/lib/
Dtsserver.js15714 … return node.importClause && ts.tryCast(node.importClause.namedBindings, ts.isNamespaceImport);
15725 …return node.kind === 264 /* ImportDeclaration */ && !!node.importClause && !!node.importClause.nam…
23573 function createImportDeclaration(decorators, modifiers, importClause, moduleSpecifier) { argument
23575 node.importClause = importClause;
23578 propagateChildFlags(node.importClause) |
23584 … function updateImportDeclaration(node, decorators, modifiers, importClause, moduleSpecifier) { argument
23587 || node.importClause !== importClause
23589 … ? update(createImportDeclaration(decorators, modifiers, importClause, moduleSpecifier), node)
25267 …ode) ? updateImportDeclaration(node, node.decorators, modifiers, node.importClause, node.moduleSpe…
27785 if (node.kind === 264 /* ImportDeclaration */ && node.importClause) {
[all …]
DtypescriptServices.js15908 … return node.importClause && ts.tryCast(node.importClause.namedBindings, ts.isNamespaceImport);
15919 …return node.kind === 264 /* ImportDeclaration */ && !!node.importClause && !!node.importClause.nam…
23767 function createImportDeclaration(decorators, modifiers, importClause, moduleSpecifier) { argument
23769 node.importClause = importClause;
23772 propagateChildFlags(node.importClause) |
23778 … function updateImportDeclaration(node, decorators, modifiers, importClause, moduleSpecifier) { argument
23781 || node.importClause !== importClause
23783 … ? update(createImportDeclaration(decorators, modifiers, importClause, moduleSpecifier), node)
25461 …ode) ? updateImportDeclaration(node, node.decorators, modifiers, node.importClause, node.moduleSpe…
27979 if (node.kind === 264 /* ImportDeclaration */ && node.importClause) {
[all …]
Dtsserverlibrary.js15908 … return node.importClause && ts.tryCast(node.importClause.namedBindings, ts.isNamespaceImport);
15919 …return node.kind === 264 /* ImportDeclaration */ && !!node.importClause && !!node.importClause.nam…
23767 function createImportDeclaration(decorators, modifiers, importClause, moduleSpecifier) { argument
23769 node.importClause = importClause;
23772 propagateChildFlags(node.importClause) |
23778 … function updateImportDeclaration(node, decorators, modifiers, importClause, moduleSpecifier) { argument
23781 || node.importClause !== importClause
23783 … ? update(createImportDeclaration(decorators, modifiers, importClause, moduleSpecifier), node)
25461 …ode) ? updateImportDeclaration(node, node.decorators, modifiers, node.importClause, node.moduleSpe…
27979 if (node.kind === 264 /* ImportDeclaration */ && node.importClause) {
[all …]

12