• tocano@lemmy.today
    link
    fedilink
    English
    arrow-up
    4
    ·
    edit-2
    22 hours ago

    The most obvious option: highlight what changed, the whole string. If you changed the string from interpolated to non-interpolated, the meaning of the whole string changed; it is no longer a method to concatenate variables, it has become a literal string.

    Same for the example of single to double quotes. In some languages, double quotes are only used in specific contexts, so its use changes the meaning of the code. The post seems to dismiss this fact too easily.