Sha256: 166fe42501b2d8c277177ca1dbf2f6c5919e6d242b026555fd22d3aeb3088117
Contents?: true
Size: 463 Bytes
Versions: 1
Compression:
Stored size: 463 Bytes
Contents
module MotionPrime module HasStyleChainBuilder def build_styles_chain(base_styles, suffixes) styles = [] [*base_styles].each do |base_style| [*suffixes].each do |suffix| components = [] components << base_style.to_s if base_style.present? components << suffix.to_s if suffix.present? styles << components.join('_').to_sym if components.present? end end styles end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
motion-prime-0.4.3 | motion-prime/helpers/has_style_chain_builder.rb |