New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

webpack-bem-plugin

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

webpack-bem-plugin

Webpack plugin to build BEM-projects

latest
npmnpm
Version
0.1.0
Version published
Maintainers
1
Created
Source

Webpack BEM plugin

Simple steps to use BEM in your React project:

  • Write components as bem-react-core declarations
  • Use bem-import-notation to import or require components
  • Define project structure in bemrc config file
  • Build project using webpack and Webpack-BEM-plugin
  • Enjoy :wink:

Examples

npm run build-examples

Each example has its public/*.html.

  • Char table (source) js no-sets no-babel
  • Few components (source) js/css sets babel
  • Promo (source) js/css sets library plugins babel

Plugin options

NameTypeDescription
[techs]{String[]}List of techs in project to build. Default is ['js']
[techMap]{Object}Maps techs to actual file extensions. Tech with no mapping treated as file extension as is. Example of custom mapping: { js: 'react.js' }
[libs]{Object}Stores inline bemrc configurations for some libraries. Use when a library has not its bemrc file and adding it in library codebase is complicated
[plugins]{Function}Callback returns 3rd party plugins with no "child-compiler" support. Example is extract-text-webpack-plugin

Run tests

npm test

Known issues

License

Code and documentation copyright 2018 YANDEX LLC. Code released under the Mozilla Public License 2.0.

Keywords

bem

FAQs

Package last updated on 19 Mar 2018

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