Skip to content

Migration refactorings after renaming from .js to .ts files #24713

Open
@DanielRosenwasser

Description

@DanielRosenwasser

At least week's design meeting, @sheetalkamat had the idea that we should consider applying refactorings for when you rename a .js file to a .ts file.

I think this is definitely worth experimenting with. From the refactoring pipeline, I could imagine things like

  • moving from CommonJS to ES Modules
  • lifting JSDoc annotations
  • moving to classes
  • inferring from usages

Then there's project configuration. I could see

  • Generating a tsconfig.json
  • Installing @types dependencies for packages that need them.

@mjbvz @amcasey

Metadata

Metadata

Assignees

No one assigned

    Labels

    Awaiting More FeedbackThis means we'd like to hear from more people who would be helped by this featureDomain: Refactoringse.g. extract to constant or function, rename symbolNeeds ProposalThis issue needs a plan that clarifies the finer details of how it could be implemented.SuggestionAn idea for TypeScript

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions