Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/qfox/node-jscs-plugin-tpl
Stub project for JSCS plugins
https://github.com/qfox/node-jscs-plugin-tpl
Last synced: 23 days ago
JSON representation
Stub project for JSCS plugins
- Host: GitHub
- URL: https://github.com/qfox/node-jscs-plugin-tpl
- Owner: qfox
- License: mit
- Created: 2014-04-04T12:02:47.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2014-04-05T05:07:43.000Z (over 10 years ago)
- Last Synced: 2024-04-09T15:37:36.164Z (7 months ago)
- Language: JavaScript
- Size: 156 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# node-jscs plugin volo tpl [![Build Status](https://travis-ci.org/zxqfox/node-jscs-plugin-tpl.svg?branch=master)](https://travis-ci.org/zxqfox/node-jscs-plugin-tpl)
JSCS plugin volo template
## To create empty stub use volo
```
npm install volo
volo create {place here your plugin name} zxqfox/node-jscs-plugin-tpl
```## Friendly packages
* JSCS: https://github.com/mdevils/node-jscs/
## Plugin installation
`jscs-plugin` can be installed using `npm`:
```
npm install jscs-plugin
```To use plugin you should add it to configuration file `.jscsrc`:
```
{
...
"additionalRules": [
'node_modules/jscs-plugin/rules/*'
]
}
```## Browser Usage
File [jscs-plugin-browser.js](jscs-plugin-browser.js) contains browser-compatible version of `jscs-plugin`.
Download and include `jscs-plugin-browser.js` into your page just after `jscs-browser.js`.
```html
var checker = new JscsStringChecker();
checker.registerDefaultRules();
checker.configure({yourPluginRules: {...}});
var errors = checker.checkString('var x, y = 1;');
errors.getErrorList().forEach(function(error) {
console.log(errors.explainError(error));
});```