Socket
Socket
Sign inDemoInstall

auto-bem-scss-commenter

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

auto-bem-scss-commenter

Automatically comment your BEM compliant SCSS files to add class name comments. (inpired by dpellier/bem-comment)


Version published
Weekly downloads
4
Maintainers
1
Weekly downloads
 
Created
Source

auto-bem-scss-commenter Build Status NPM version

Automatically comment your BEM compliant SCSS files to add class name comments. (inpired by dpellier/bem-comment)

Installation

Auto-bem-scss-commenter can be installed using

$ npm install --save-dev auto-bem-scss-commenter 

Usage

// file.scss 
//

.object {
  /* styles */

  &__child {
    /* styles */

    &--modifier {
      /* styles */
    }
  }
}
auto-bem-scss-commenter file.scss > file.scss 
// file.scss 
//

// object
.object {
  /* styles */

  // object__child
  &__child {
    /* styles */

    // object__child--modifier
    &--modifier {
      /* styles */
    }
  }
}

auto-bem-scss-commenter -h for more info

With Node

var bemComment = require('auto-bem-scss-commenter ');
gulp.task('helper:bem-comment', function () {
  return gulp.src(['**/{,*/}/*.scss'], {cwd: options.app})
    .pipe(bemComment({ force: true }))
    .pipe(gulp.dest(options.app));
});

The force option force rewrite all comments

License

Copyright © 2014 Douglas Duteil <douglasduteil@gmail.com>
This work is free. You can redistribute it and/or modify it under the
terms of the Do What The Fuck You Want To Public License, Version 2,
as published by Sam Hocevar. See the LICENCE file for more details.

Keywords

FAQs

Package last updated on 13 Feb 2015

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc