Code Monkey home page Code Monkey logo

Comments (10)

gasi avatar gasi commented on August 20, 2024

+1

This issue and the mess the old cookie library creates in Express made me (temporarily) implement my own minimal Twitter client.

Have you considered taking advantage of some tools and libraries to make development easier and the code simpler?
Check out this implementation using CoffeeScript and Streamline.js:
https://github.com/gasi/node-twitter2/blob/develop/lib/twitter_.coffee

CoffeeScript gives us an abstraction for classes, string interpolation, etc. and Streamline really simplifies async code.

Let me know if you're interested in collaborating.

from node-twitter.

jdub avatar jdub commented on August 20, 2024

Sorry, but I'd like to stick to straight JS and callbacks for node-twitter. It'd be nice if you renamed your repo so no one is confused about the relationship between node-twitter and your own library. Thanks.

(The cookie issue is being resolved at the moment -- see the pull request.)

from node-twitter.

gasi avatar gasi commented on August 20, 2024

I respect your decision. Regarding the name, no worries, once your library doesn't rely on cookie and has standard callbacks, I'll probably kill mine. If I remember correctly, I read you mentioning to kill off the middleware & login part that relies on cookies. Is that true? I for one would welcome it very much.

Nice work on node-twitter :)

from node-twitter.

jdub avatar jdub commented on August 20, 2024

I'll move it to a different module (included with node-twitter or separate, haven't decided).

from node-twitter.

gasi avatar gasi commented on August 20, 2024

Cool, looking forward to check it out.

from node-twitter.

ealdent avatar ealdent commented on August 20, 2024

+1 loving the library and this would be really nice to have

from node-twitter.

jdub avatar jdub commented on August 20, 2024

Check out the request branch for a first cut of this. Every post-0.1.18 release will use the standard node callback pattern. :-)

from node-twitter.

aseemk avatar aseemk commented on August 20, 2024

Sweet! Looking forward to it. Thanks @jdub.

from node-twitter.

jdub avatar jdub commented on August 20, 2024

Just waiting on some fixes to request before merging the new request (and standard callback pattern) branch.

from node-twitter.

gasi avatar gasi commented on August 20, 2024

Here json is returned as first argument, even though it is the success case:

callback(json);

Is this an oversight or did you decide not to use the callback(error, result) pattern?

P.S. Here I am, three years later, working for a different company and a different product and ran into the same issue. Made me chuckle seeing myself having commented on this back then 😉

/cc @aseemk

from node-twitter.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.