TypeScript/tests/cases/fourslash/refactorConvertToEs6Module_export_invalidName.ts

19 lines
358 B
TypeScript

/// <reference path='fourslash.ts' />
// Test that we leave it alone if the name is a keyword.
// @allowJs: true
// @target: esnext
// @Filename: /a.js
////exports.class = 0;
////exports.async = 1;
verify.codeFix({
description: "Convert to ES6 module",
newFileContent:
`const _class = 0;
export { _class as class };
export const async = 1;`,
});