parse-bem-identifier

4.0.0 • Public • Published

parse-bem-identifier NPM version Build Status Dependency Status

Parsing B__E_M identifier.

You can learn about identifier structure from tests.

API

parseBemIdentifier(string, [options])

Parses string as BEM identifier and returns object, that contains:

  • block
  • mod
  • modVal
  • elem
  • elemMod
  • elemVal

options

short

Type: Boolean
Default: false

If true, then elemMod will be stored in mod, modVal and elemVal will be stored in val.

License

MIT (c) 2014 Vsevolod Strukchinsky (floatdrop@gmail.com)

Readme

Keywords

Package Sidebar

Install

npm i parse-bem-identifier

Weekly Downloads

0

Version

4.0.0

License

MIT

Last publish

Collaborators

  • floatdrop