Advertisement
Guest User

Untitled

a guest
Dec 20th, 2014
147
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.44 KB | None | 0 0
  1. // Before introducing promises, each of these functions required a callback to be passed in to it.
  2. // This leads to deeply nested structures and the arrow-anti-pattern, creating more visual complexity
  3. // and reducing the maintainability of this code
  4.  
  5. Tiles.getImagesForTile(function(images){
  6. Tiles.buildThumnails(images, function(thumbnails){
  7. Tiles.transmogrify(thumbnails, function(notification){
  8. updater.update(notification);
  9. }
  10. });
  11. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement