• Traister101@lemmy.today
    link
    fedilink
    arrow-up
    2
    ·
    6 months ago

    Tabs are objectively the better choice as it allows each dev individually to decide tab width in their editors. Spaces in contrast don’t allow this same flexibility as they are used for much more than simply indentation, for example you likely put a space after each argument or operator IE func(arg1, arg2) or 1 + 2.

    • zea@lemmy.blahaj.zone
      link
      fedilink
      arrow-up
      1
      ·
      6 months ago

      Also, a lot of editors won’t unindent on backspace of spaces indentation, so I end up messing up the indentation with a 3/4 indent

    • expr@programming.dev
      link
      fedilink
      arrow-up
      0
      ·
      6 months ago

      Code can be viewed in more than just an editor. It might be in a terminal, rendered in a browser, etc. Sometimes you might even have to view it in an environment you don’t control. I am very disinterested in configuring each and every tool to have sensible tabstops, if such a tool can even be configured.

      • Traister101@lemmy.today
        link
        fedilink
        arrow-up
        2
        ·
        6 months ago

        Then don’t? The whole reason nearly all the spaces guys do 4 spaces is cause that’s the nearly universal tab width. You won’t like this but the same exact argument can be made for spaces yet I’d bet you haven’t even once configured the width of those.

        I don’t actually change tab width, it’s the default 4 spaces equivalent for me but just because I don’t take advantage of the ability doesn’t mean I should prevent others from doing so.