Skip to content


BitTorrent in JavaScript with Node

A few months ago I tried to make a bittorrent client in javascript. But a few days after it started, I found out that there were already other projects with the same goal. The most complete of them was summerTorrent. However, though (I thought) it was so insanely close, it wasn’t finished. So anyway, I made a few changes that at least made basic torrenting functionality working.

summerTorrent

Posted in P2P.

Tagged with , , , , .


7 Responses

Stay in touch with the conversation, subscribe to the RSS feed for comments on this post.

  1. Nils says

    Why didn’t you send a pullrequest back to upstream? Or did it just get declined?

  2. admin says

    A lot of it was really hacky, I don’t think it’s worthy of getting upstream.

  3. Lorenz says

    to check for a Object type in JS use its constructor.

    In your case (bencoding.js), you can use
    o.constructor === Array
    > true

    instead of this, which involves more overhead:

    Object.prototype.toString.call(o) == ‘[object Array]‘

    also be aware of fallacy of the logical operators in JS, like !!; ===, !== etc… vs !,==,!=

  4. Lorenz says

    to check for a Object type in JS use its constructor.

    In your case (bencoding.js), you can use
    o.constructor === Array
    > true

    instead of this, which involves more overhead:

    Object.prototype.toString.call(o) == ‘[object Array]‘

    also be aware of fallacy of the logical operators in JS, like !!; ===, !== etc… vs !,==,!=

    PS: Good work

  5. coyo says

    oh, this is really cool! keep up the good work! i want to see full functionality with this! please!

    Also, setup a flattr, so i can flattr you.

  6. Payday Loan Vancouver Bc says

    What’s up Dear, are you really visiting this site on a regular basis, if so
    then you will without doubt take pleasant knowledge.

  7. auto title loans says

    My relatives always say that I am wasting my time here at web, but
    I know I am getting know-how daily by reading thes good posts.



Some HTML is OK

or, reply to this post via trackback.