Fold comments by default


#1

Is there any way to have the default behavior of the editor to fold comments by default? If I have some comment like so:

/**
 * Function description...
 * @return something
 */
function foo() {
    ...
}

I’d like the comment to be folded by default when opening the file, like so:

/**...
function foo() {
    ...
}

#2

Not built-in to Atom, no. But someone could write a package for it, I’d bet.


#3

Try Fold-comments package with “autofolding” option enabled.


#4

Fold-comments looks like what I want. Thanks!