I did take a look at the Promises/A implementations but they were for server-side solutions and so tied into their own API terminology in places and was just confusing to follow along to.
At least with the jQuery I know the API already so I'll just have to go through the link you provided to their deferred script and muddle my way through. Thanks for the link, and thanks to everyone who posted a reply. Kind regards, Mark -- Mark McDonnell On Tuesday, 29 March 2011 at 14:32, Poetro wrote: > 2011/3/29 Mark McDonnell <[email protected]>: > > Hi Scott, > > Essentially I would like to use Promises in the same way as used by jQuery > > 1.5 (or at least how their AJAX API uses it) but I just don't have the first > > clue on how to implement it in actual JavaScript code? > > I understand that there are different implementations of Promises and > > looking through them it seems that jQuery's was based on Promises/A API so I > > guess that is the one I'd most likely want to try and implement. > > Again, I just don't understand how to implement it. > > I've found a few very basic variations... > > > > https://gist.github.com/814313 > > https://gist.github.com/814318 > > > > ...but I'm not sure how you would go about using these as examples? > > Regards, > > Mark > > > > -- > > Mark McDonnell > > Did you look at the Promises/A implementation that are listed at > http://wiki.commonjs.org/wiki/Promises/A#Implementations ? And also > you can look at the jQuery implementation at > https://github.com/jquery/jquery/blob/master/src/deferred.js . > > -- > Poetro > > -- > To view archived discussions from the original JSMentors Mailman list: > http://www.mail-archive.com/[email protected]/ > > To search via a non-Google archive, visit here: > http://www.mail-archive.com/[email protected]/ > > To unsubscribe from this group, send email to > [email protected] > -- To view archived discussions from the original JSMentors Mailman list: http://www.mail-archive.com/[email protected]/ To search via a non-Google archive, visit here: http://www.mail-archive.com/[email protected]/ To unsubscribe from this group, send email to [email protected]
