bogas04 / SikhJS

👳 🚀 Gurbani Progressive Web Application
https://bogas04.github.io/SikhJS
MIT License
26 stars 16 forks source link

Implement brilliant idea of use of colors from larivaar.com #56

Closed bogas04 closed 7 years ago

bogas04 commented 7 years ago

Initial method of implementing:

line
  .split(' ')
  .map((akhar, index) => (
    index % 2 == 0
      ? <span style={{ color: 'orange' }}>{akhar}</span>
      : akhar
   ))
  .join('');

I think this will still have to take care of || and other symbols. Also, CSS way of implementing this can be used for cleaner DOM.