fis3-lint-rich-stylelint

    1.1.9 • Public • Published

    fis3-lint-rich-stylelint

    • The fis3-lint-rich-stylelint library exported as a fis3 plugin.

    npm node npm

    Dependencies

    Installation

    $ npm install fis3-lint-rich-stylelint [--save-dev]

    Usages

    fis.match('*.js', {
        lint: fis.plugin('rich-stylelint'[, options])
    })
     

    See the options what is same as stylelint lint for more details.

    Default configs

    {
        'fix': false,
        'allowOutfixed': false,
        'code': fileText,
        'formatter': 'string',
        'useEslintrc': false,
        'ignoreFiles': [
            'bower_components/**',
            'node_modules/**',
            'lint-fixed/**'
        ],
        'config': {
            'rules': rules
        }
    }

    allowOutfixed: Boolean | [Boolean, options]

    Output the restored file to the directory '/lint-fixed/**', the premise is that the value of fix is true

    options

    • 'root': true Get root permissions, it will modify the source file,this operation does't promise correctness, so be careful!!!
    • 'dirname': '/lint-fixed' Specify the root directory of the repaired file output

    ignoreFiles: [String]

    Glob patterns for paths to ignore.

    Rules

    As mentioned above, the following is introduce of rules:

    Stylelint-config-lagou

    配置参考stylelint-config-lagou定义

    Turning rules off from within your CSS

    • turn all the rules off:
    /* stylelint-disable */
    a {}
    /* stylelint-enable */
    • turn off specified rules:
    /* stylelint-disable selector-no-id, declaration-no-important  */
    #id {
      color: pink !important;
    }
    /* stylelint-enable */
    • turn off specified line and rules:
    #id { /* stylelint-disable-line */
      color: pink !important; /* stylelint-disable-line declaration-no-important */
    }
    #id {
      /* stylelint-disable-next-line declaration-no-important */
      color: pink !important;
    }

    Install

    npm i fis3-lint-rich-stylelint

    DownloadsWeekly Downloads

    1

    Version

    1.1.9

    License

    ISC

    Unpacked Size

    11.7 kB

    Total Files

    5

    Last publish

    Collaborators

    • ice.tang