Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Tools to enforce a coding style for Javascript [closed]

I need to automatically check the style of javascript sources written by different people. Do you know of a good tool to do it? Integration with emacs would be a plus. Thank you in advance.

like image 359
Stefano Avatar asked Dec 27 '08 13:12

Stefano


People also ask

How do you enforce code styling in a project?

Use an EditorConfig file when you want to enforce coding styles for all contributors to your repo or project. You can manually populate your EditorConfig file, or you can automatically generate the file based on the code style settings you've chosen in the Visual Studio Options dialog box.

What is a code style guide?

A style guide tells a developer how to work with a particular programming language. Programming style guides are composed of rules and guidance. Rules are mandates, with very few exceptions, enforceable throughout the entire IT organization. Rules make good and bad programming behavior explicit.


1 Answers

See EditorConfig. This tool is not limited to js though; You first install the plugin for your editor (there is an emacs plugin), and create a file named .editorconfig, whose content is the coding style.

like image 200
xuhdev Avatar answered Oct 26 '22 11:10

xuhdev