4 ms·
or just use async which fixes both of these arguably broken solutions for callback hell.
by throwasehasdwi 10y ago
or just use async which fixes both of these arguably broken solutions for callback hell.
- hugozap 10y agoMost 'callback hell' situations are really just poor code structure. Easily solved with separated named functions.
- throwasehasdwi 10y agoThis is easy to say but hard to do in practice. Every JS application I've seen in production is littered with callback nightmares. It might be possible to avoid but in practice it's too difficult. async makes it easy and I don't see a downside to using it everywhere possible.