Maybe I've gotten so used to callbacks and taming them into elegant code, but I have yet to see examples of promises where I'm like "ah-ha, that's an awesome example of when this looks a ton nicer". Most examples feel quite trivial and contrived (i.e. foo/bar/baz examples and doSomething() examples).
Can some one please point me to fairly complex examples comparing and contrasting a sample of code that uses callbacks to perform a task and another same that uses promises to accomplish the same task? Thanks in advance.
Can some one please point me to fairly complex examples comparing and contrasting a sample of code that uses callbacks to perform a task and another same that uses promises to accomplish the same task? Thanks in advance.