Skip to content
This repository was archived by the owner on Feb 12, 2022. It is now read-only.

Commit 91be8c2

Browse files
Adding editorconfig file and my personal webstorm settings file (just the file formatting part of it).
1 parent cde9a96 commit 91be8c2

File tree

3 files changed

+35
-0
lines changed

3 files changed

+35
-0
lines changed

.editorconfig

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
root = true
2+
3+
[*]
4+
indent_style = tab
5+
end_of_line = lf
6+
charset = utf-8
7+
trim_trailing_whitespace = true
8+
insert_final_newline = true
9+
10+
[package.json]
11+
indent_style = space
12+
indent_size = 2
13+
14+
[*.md]
15+
trim_trailing_whitespace = false
16+
17+
[*.js]
18+
curly_bracket_next_line = false

README.md

+17
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@
3030
1. [ES5 Compatibility](#es5)
3131
1. [Testing](#testing)
3232
1. [Performance](#performance)
33+
1. [Editorconfig Setup / Use](#editorconfig)
3334
1. [Resources](#resources)
3435
1. [In the Wild](#in-the-wild)
3536
1. [The JavaScript Style Guide Guide](#guide-guide)
@@ -1195,6 +1196,22 @@
11951196
- Loading...
11961197
11971198
**[[⬆]](#TOC)**
1199+
1200+
## <a name='editorconfig'>Editorconfig Setup / Use</a>
1201+
- Usually for a project with more than one developer involved, it is essentially important for the project to define
1202+
and maintain a consistent coding style. Most code editors and IDEs, such as Vim, Emacs, Code::Blocks, provide settings
1203+
related to coding styles, such as the width of tab, the size of indentation, end of line, etc. However, it is hard to
1204+
provide the same settings for different Editors and IDEs: we have to maintain many config files for different editors
1205+
and IDEs, such as .vimrc for Vim, .emacs for Emacs. In order to solve this, EditorConfig was born. By defining coding
1206+
style in files named .editorconfig, the EditorConfig plugins for different editors and IDEs will automatically adjust
1207+
your coding style.
1208+
- To use EditorConfig, you have to download the corresponding [EditorConfig plugins](http://editorconfig.org/#download) for your Editor or IDE.
1209+
Follow the installation instructions to install them.
1210+
- The "base" .editorconfig file goes in the root directory. You can have other config files in specific folders if wanted.
1211+
The only difference would be at the top of the file to remove <code>root = true</code> from any file that isn't the root.
1212+
1213+
1214+
**[[⬆]](#TOC)**
11981215
11991216
12001217
## <a name='resources'>Resources</a>

linters/webstorm-settings.jar

1.23 KB
Binary file not shown.

0 commit comments

Comments
 (0)