Giter Site home page Giter Site logo

atom-jsfmt's Introduction

atom-jsfmt

David

atom-jsfmt is a jsfmt plugin for the Atom text editor. jsfmt is really good at formatting, searching, and rewriting javascript. It's pretty nifty.

atom-jsfmt in action

What does it do?

  • Format your code: Run the Jsfmt: Format command to keep your code well-styled.
  • Format on save: atom-jsfmt will auto-format your javascript every time you save, so you don't have to think about it.

How do I get it?

Installation can be done from Atom's package browser (just search for atom-jsfmt). You can also use the apm command line installer:

apm install atom-jsfmt

How do I tweak the formatting?

Although the default style guide is pretty good, you may find yourself wanting to tweak the formatting. atom-jsfmt looks for the closest .jsfmtrc file before formatting (you can read more about them here). It checks the directory of the current file, and keeps moving up directories until it finds something.

For example, if you like your code indented four spaces, your .jsfmtrc might look like this:

{
    "indent": {
        "value": "    "
    }
}

Options

  • Show Errors: Whether or not you want to see error messages. You probably do. This is set to true by default.
  • Format On Save: Whether or not you automatically want to format your javascript files when you save. Defaults to true.

To do

  • Look for .jsfmtrc files in all the places that the command line tool looks (like /etc/.jsfmtrc or ~/.jsfmtrc).
  • Add searching / rewriting functionality
  • Flag lines with errors

Credit

  • jsfmt is written and maintained by the good folks at rdio.

Changelog

The changelog can be viewed here.

License

Atom-jsfmt is licensed under the MIT license, which can be viewed here.

atom-jsfmt's People

Contributors

andrewn avatar salemhilal avatar

Watchers

 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.