mirror of
https://github.com/bendtherules/eslint-plugin-no-classname-with-stylename.git
synced 2026-08-18 13:53:24 +00:00
32 lines
898 B
JavaScript
32 lines
898 B
JavaScript
/**
|
|
* @fileoverview While using CSS Modules, disallow using (non-conditional / string) classNames in a JSX tag if it already has a styleName
|
|
* @author Abhas Bhattacharya
|
|
*/
|
|
"use strict";
|
|
|
|
//------------------------------------------------------------------------------
|
|
// Requirements
|
|
//------------------------------------------------------------------------------
|
|
|
|
var requireIndex = require("requireindex");
|
|
|
|
//------------------------------------------------------------------------------
|
|
// Plugin Definition
|
|
//------------------------------------------------------------------------------
|
|
|
|
|
|
// import all rules in lib/rules
|
|
module.exports.rules = requireIndex(__dirname + "/rules");
|
|
|
|
module.exports.configs = {
|
|
recommended: {
|
|
plugins: ['no-classname-with-stylename'],
|
|
|
|
rules: {
|
|
'no-classname-with-stylename/no-classname-with-stylename': 2,
|
|
},
|
|
},
|
|
};
|
|
|
|
|