Skip to content
This repository has been archived by the owner on Nov 20, 2022. It is now read-only.
/ purebem-elm Public archive

A BEM CSS methodology utility helper

License

Notifications You must be signed in to change notification settings

gravplats/purebem-elm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 

Repository files navigation

purebem-elm

A BEM CSS methodology utility helper

A simple Elm utility for creating BEM standard CSS class names. This is a port of purebem-js.

Usage

import Purebem exposing (purebem)


blockOnly : String
  let
    block = purebem("my-block")
  in
    purebem "" []
    -- "my-block"


blockElement : String
  let
    block = purebem("my-block")
  in
    purebem "my-element" []
    -- "my-block__my-element"


blockElementModifiers : String
  let
    block = purebem("my-block")
  in
    purebem "my-element" [("my-modifier-1", True), ("my-modifier-2", False)]
    -- "my-block__my-element my-block__my-element--my-modifier-1"

License

BSD3

About

A BEM CSS methodology utility helper

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages