https://github.com/bem/jscs-bem
jscs bem preset and some tasty rules
https://github.com/bem/jscs-bem
Last synced: about 1 year ago
JSON representation
jscs bem preset and some tasty rules
- Host: GitHub
- URL: https://github.com/bem/jscs-bem
- Owner: bem
- License: other
- Created: 2014-12-26T13:25:59.000Z (over 11 years ago)
- Default Branch: master
- Last Pushed: 2016-02-03T18:42:56.000Z (over 10 years ago)
- Last Synced: 2024-09-30T21:49:51.672Z (over 1 year ago)
- Language: JavaScript
- Size: 15.6 KB
- Stars: 6
- Watchers: 27
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# jscs-bem
Plugin for [`jscs`][] with `bem` code style preset.
## What is it?
A preset library for [`jscs`][] (code-style linter) with examples and `bem`-specific code-style checks.
### Presets inside
- `bem` — used in [`bem-core`][] v3+ code base and [`bem-components`][] v2+;
- `canonical-bem` — used in [`bem-core`][] v2 and [`bem-components`][] below v2.
## Usage
To use it you need fresh [`jscs`][], and simple `.jscsrc` file in your project root.
Run in your project root to quick start:
```sh
npm i jscs jscs-bem --save-dev
echo '{ plugins: ["jscs-bem"], preset: "bem" }' > .jscsrc
```
## Contribution
1. [File an issue](https://github.com/bem/jscs-bem/issues/new) with properly described suggestion or problem;
2. Decide which presets or rules your issue affects;
3. Create a feature-branch with an issue number (`issues/`). E.g. for an issue 42 it will looks like `issues/42`;
4. Commit changes with a proper message, e.g.:
```js
:
[]
Fixes #
[Ref #]
```
5. Push and make a pull-request from your feature-branch.
6. Link your pull request with an issue number any way you like (if you forget to do it in commit message). A comment will work perfectly.
7. Wait for your pull request and the issue to be closed ;-)
## Licence
Code and documentation copyright 2015 YANDEX LLC. Code released under the [Mozilla Public License 2.0](LICENSE.txt).
[`jscs`]: http://jscs.info/
[`bem-core`]: http://bem.info/libs/bem-core
[`bem-components`]: http://bem.info/libs/bem-components