Skip to content

"Remove braces from arrow function": comment inside parentheses is lostΒ #44229

Open
@OliverJAsh

Description

@OliverJAsh

Bug Report

πŸ”Ž Search Terms

vs code quick fix code action source

πŸ•— Version & Regression Information

  • This is the behavior in every version I tried, and I reviewed the FAQ for entries about refactorings

⏯ Playground Link

N/A

πŸ’» Code

const fn = () => {
    return (
        // foo
        1
    );
};
  1. Run refactoring "Remove braces from arrow function"

πŸ™ Actual behavior

const fn = () => (
    1
);

πŸ™‚ Expected behavior

const fn = () => (
    // foo
    1
);

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugA bug in TypeScriptDomain: Refactoringse.g. extract to constant or function, rename symbolHelp WantedYou can do this

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions