Skip to content

Commit

Permalink
feat: parallelise loading dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
pemrouz committed Nov 19, 2017
1 parent 7b41c7d commit a7b35e3
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,13 @@ const render = ripple => next => el => {

return attrs
.map(([name, values]) => {
return values.some((v, i) => {
const from = attr(el, name) || ''
return includes(v)(from) ? false
: attr(el, name, (from + ' ' + v).trim())
})
return values
.map((v, i) => {
const from = attr(el, name) || ''
return includes(v)(from) ? false
: attr(el, name, (from + ' ' + v).trim())
})
.some(Boolean)
})
.some(Boolean) ? el.draw() : next(el)
}
Expand Down

0 comments on commit a7b35e3

Please sign in to comment.