b94061c587
* getEditsForFileRename: Avoid changing import specifier ending * Support .json and .jsx extensions * Restore typeRoots tests * Fix json test * When --jsx preserve is set, import ".tsx" file with ".jsx" extension * Support ending preference in UserPreferences
27 lines
499 B
TypeScript
27 lines
499 B
TypeScript
/// <reference path="fourslash.ts" />
|
|
|
|
// @moduleResolution: classic
|
|
|
|
// @Filename: /node_modules/@types/foo/index.d.ts
|
|
////export const xyz: number;
|
|
|
|
// @Filename: /node_modules/bar/index.d.ts
|
|
////export const qrs: number;
|
|
|
|
// @Filename: /a.ts
|
|
////xyz;
|
|
////qrs;
|
|
|
|
goTo.file("/a.ts");
|
|
verify.codeFixAll({
|
|
fixId: "fixMissingImport",
|
|
fixAllDescription: "Add all missing imports",
|
|
newFileContent:
|
|
`import { xyz } from "foo";
|
|
|
|
import { qrs } from "./node_modules/bar/index";
|
|
|
|
xyz;
|
|
qrs;`,
|
|
});
|