GithubHelp home page GithubHelp logo

forivall / atom-fold-functions Goto Github PK

View Code? Open in Web Editor NEW

This project forked from robballou/atom-fold-functions

0.0 3.0 0.0 94 KB

Folds functions within your code

License: MIT License

CoffeeScript 100.00%

atom-fold-functions's Introduction

Fold Functions

Folds functions within your code. Currently comes with a toggle, fold, and unfold option that will look for functions marked with 'meta.function'. Handy because it won't fold things like comments associated with functions.

screenshot

Note: this currently folds only those functions it finds at a single indentation (e.g. it will fold the top level functions)

Heavily inspired/influnced by Fold Comments.

Autofolding

You can turn on the auto-folding feature with the following in your configuration file:

"fold-functions":
    autofold: true
    shortfileCutoff: 42
    autofoldGrammars: []
    autofoldIgnoreGrammars: ['SQL', 'CSV', 'JSON', 'CSON', 'Plain Text']

By default, this is setup to ignore files that are under 42 lines. This can be configured by changing the shortfileCutoff option to a larger or smaller number. If you wish to fold all files, even short ones, you can change this option to 0.

Additionally, two new autofolding options have been added in 0.4.2:

  1. autofoldGrammars allows you to specify grammar names for grammars you want to autofold. An empty list (which is the default), means everything is fair game to fold. That is except...
  2. autofoldIgnoreGrammars allows you to specify grammar names for grammars you do not want to autofold. This fires after autofoldGrammars and does have a default value (see above).

atom-fold-functions's People

Contributors

robballou avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.