Skip to content

Bad template string refactor w/ existing template strings #44396

@elibarzilay

Description

@elibarzilay

Doing a Convert to template string refactors

const a = `x` + `y` + text + "z";

to

const a = `${`x` + `y` + text}z`;

which isn't invalid but would be better to convert it to

const a = `xy${text}z`;

(There is also a point to not do the refactor at all when the author meant to split the template strings, but in that case they just won't use the refactor.)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions