b834096998
* Fix #37948 * Fix formatter skipping tab/space fixup on comments, handle trailing commas in list closing line count. Fixes #37944 * Add newline between imports and main body of new file in moveToNewFile Fixes #37941 * Update baseline (probably broken before?)
36 lines
620 B
TypeScript
36 lines
620 B
TypeScript
/// <reference path='fourslash.ts' />
|
|
|
|
// @module: esnext
|
|
// @allowJs: true
|
|
|
|
// @Filename: /a.js
|
|
////const { a, b } = require("./other");
|
|
////const p = 0;
|
|
////[|const y = p + b;
|
|
////const z = 0;
|
|
////exports.z = 0;|]
|
|
////a; y; z;
|
|
|
|
// @Filename: /user.ts
|
|
////const { x, y } = require("./a");
|
|
|
|
verify.moveToNewFile({
|
|
newFileContents: {
|
|
"/a.js":
|
|
`const { a, } = require("./other");
|
|
const { y, z } = require("./y");
|
|
const p = 0;
|
|
exports.p = p;
|
|
a; y; z;`,
|
|
|
|
"/y.js":
|
|
`const { b } = require("./other");
|
|
const { p } = require("./a");
|
|
|
|
const y = p + b;
|
|
exports.y = y;
|
|
const z = 0;
|
|
exports.z = 0;
|
|
`,
|
|
},
|
|
});
|