cordova-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Josh Soref <>
Subject Re: [Node 101] Part 2: Avoid the Triangle of Doom
Date Thu, 12 Dec 2013 23:41:07 GMT
Brian wrote:
>Flatten your async code. New fashion advocates promises, generators,
>events, or one of the streams apis.

While flattening with promises is greatŠ

>The classic method is to write small testable modules (see part 1) and
>flatten your tree.
>Turn code that looks like this [1] into this [2].

Š I can¹t figure out how your two example blobs relate.

For the sake of people trying to learn patterns, can you please ensure
that your [1] and [2] are obvious ³before² and ³after²?


This transmission (including any attachments) may contain confidential information, privileged
material (including material protected by the solicitor-client or other applicable privileges),
or constitute non-public information. Any use of this information by anyone other than the
intended recipient is prohibited. If you have received this transmission in error, please
immediately reply to the sender and delete this information from your system. Use, dissemination,
distribution, or reproduction of this transmission by unintended recipients is not authorized
and may be unlawful.

View raw message