• SokathHisEyesOpen@lemmy.ml
    link
    fedilink
    English
    arrow-up
    13
    arrow-down
    1
    ·
    11 months ago

    Code comments are useful for browsing a script and understanding it at a glance. I shouldn’t have to scroll up and down across 700 lines of code to figure out what’s happening. It’s especially useful with intellisense, since I can just hover over a function and get a tooltip showing the comment, explaining what it does. It also helps when using functions imported from other files, since it’ll populate the comment showing me what parameters are needed and what each should be. Comments save time, and time is valuable.