We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 19421
    • 5 Posts
    (re style guide for coding - indentation)
    ...whilst perusing the documentation for MODx Revolution I noticed this ..

    MODx Revolution Documentation - Indentation and Line Breaks
    Code Standards
    This page was heavily borrowed from Fellowship One’s Design Standards. Thanks!

    - General Practices

    - - Indentation and Line Breaks
    All indentation must be done with 4 spaces, not tabs. Make sure to change your editor settings to reflect this.

    Fellowship Design Standards - Indentation
    Code Standards

    - General Practices

    - - Indentation
    For all code languages, we require indentation to be done via hard tabs (using the tab key character), as opposed to an arbitrary number of spaces.

    There seems to have been a clear decision to switch from the original borrowed-from-guide’s preference for tab indents and instead advise that spaces should be used.

    What’s behind the preference for spaces rather than tabs?

    I suppose it’s not important. But still .. can’t help but be intrigued.
      • 28215
      • 4,149 Posts
      Tabs are inconsistent across charset and encodings, and dont handle well with all SVN environments.
        shaun mccormick | bigcommerce mgr of software engineering, former modx co-architect | github | splittingred.com