Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    Nicolás Fantone
    @nfantone
    to my knowledge, there's only one outstanding (major) issue that needs to be addressed before moving out of alpha: pillarjs/router#102
    I have worked on it and, IMHO, it should be ready for merging - unfortunately, effort seems to have died out due to lack of communication/time from maintainers
    Nicolás Fantone
    @nfantone
    if anyone wants to contribute and give a hand, a very simple way would be to show support and participate on that issue
    Douglas Wilson
    @dougwilson
    Hi @euoia I ended up going to the emergency room right befire Christmas and so was unable to get the 5.0 beta released, but I did get a 4.x patch. I have received 4 security vulnerability reports in the interim and will need to triage / address / make some additional 4.x releases as soon as I am discharged before I can resume 5.x work. I hope that answers your question. Let me know if you would like any further information and happy new year everyone. Sorry for the set back and I think we can get 5.0 released before the end of January, as there is almost nothing left there. I pushed some more commits to the 5.0 branch but just didn't get to cut a new release off it yet.
    Nicolás Fantone
    @nfantone
    hey @dougwilson, many thanks for the update and very sorry to hear about your personal situation; hope you're feeling much better now! With regards to the vulns: would there be someone else that could be taking a look at those in the meantime? I'm up for it, if you need a hand.
    James Pickard
    @euoia
    Hi @dougwilson, I really appreciate the update. When I was looking through the GitHub issues again I saw your comment about recovering from sickness, and I'm sorry to hear you've been unwell again. I am going to see if I can get a pull request together for expressjs/expressjs.com#1313 and would also be happy to look at security issues if it's of any help. I will read through pillarjs/router#102 and see if there's anything I can contribute there.
    James Pickard
    @euoia
    I've read through the pillarjs/router#102 issue - should I have a stab at updating the migration guide to mention these changes? https://github.com/expressjs/expressjs.com/blob/gh-pages/en/guide/migrating-5.md
    Nicolás Fantone
    @nfantone
    I think that'd be nice
    James Pickard
    @euoia
    Ok, will do
    I'm just looking at the description of callback functions here
    Is there a reason the documentation doesn't use the term "request handler" or something like that? If you define a callback without a next parameter, is it still considered a middleware?
    All the examples in the middleware callback function examples have the next parameter https://expressjs.com/en/5x/api.html#middleware-callback-function-examples
    James Pickard
    @euoia
    I think things would be clearer if handler functions were described as distinct from middleware
    The distinction being that middleware must call next, and the handler function must come last
    Nicolás Fantone
    @nfantone
    I don't know that there's an "official stance" on this, but I personally have used them interchangeably in the past
    James Pickard
    @euoia
    Ok, I will have a go at rewording it as part of this PR and perhaps we can discuss from there
    Nicolás Fantone
    @nfantone
    I mean, what would you call a handler that may call next on a given path, but not on others? I think it's rather subjective
    James Pickard
    @euoia
    Maybe I'd consider calling anything that sometimes calls next a middleware
    Nicolás Fantone
    @nfantone
    that might make sense, sure - in a more broad sense, I would call anything that takes in x and is expected to do something with it an "x handler"
    error handler, event handler, request handler, etc.
    James Pickard
    @euoia
    Maybe the docs should be clearer that a callback is expected to either 1) send a response, or 2) call next()?
    Would you say that's accurate?
    1 reply
    James Pickard
    @euoia
    James Pickard
    @euoia
    I created a pull request to update the documentation around async callbacks / middleware / request handlers
    James Pickard
    @euoia
    @nfantone I am just trying to understand the updated path-to-regexp documentation https://github.com/pillarjs/router/blob/27ca41b4aa9fce28948b96addbb8d8b67698dfa9/HISTORY.md
    Where it says "would match" or "would result" does that mean it used to but no longer does?
    1 reply
    In terms of impact on Express, for migrating Express from 4 to 5, I need to look at changes between n path-to-regexp 3.2.0 and 6.2.0, is that right (I'm basing that on the change to package.json in https://github.com/pillarjs/router/pull/102/files)
    1 reply
    James Pickard
    @euoia
    I guess I just need to copy those 4 bullet points, perhaps reword them to make them more Express-oriented
    James Pickard
    @euoia
    Ok @nfantone pull request created in the documentation repo expressjs/expressjs.com#1316
    James Pickard
    @euoia
    I reckon we should probably remove references to Express 3 in the v5 migration, I can't imagine it's very relevant to many people
    1 reply
    The app.router object, which was removed in Express 4, has made a comeback in Express 5. In the new version, this object is a just a reference to the base Express router, unlike in Express 3, where an app had to explicitly load it.
    James Pickard
    @euoia
    @nfantone @dougwilson are you aware of anything else I could help with?
    Nicolás Fantone
    @nfantone
    Nicolás Fantone
    @nfantone
    @euoia also reviewed expressjs/expressjs.com#1315
    James Pickard
    @euoia
    @iron2414mw did you figure it out?
    Norbert Varjasi
    @iron2414mw
    @euoia I did, took me sometime tho. The trick was to remove objects from the router stack, filtering them by path. Then it's gone, and I can even declare it again, if I want
    James Pickard
    @euoia
    ah right, interesting
    @crandmck are you still involved in Express documentation at all? We could use your help reviewing some documentation changes please
    James Pickard
    @euoia
    @dougwilson @nfantone the next milestone we're working towards, is that releasing Express v5 as a beta or releasing it as the main stable version (i.e. npm install express gives you v5)?
    2 replies
    James Pickard
    @euoia

    @nfantone did you get a resolution for your comment here https://github.com/expressjs/express/pull/4321#issuecomment-1003836216 ?

    I'm confused. Once pillarjs/router#102 is merged, a new (beta?) version of router would need to be cut and express would need to be updated again.

    Also changes in 1574925 were already part of #4752, which was put on hold and marked as "Draft" until the above takes place, but I see no mention of this.

    2 replies
    Tim Chen
    @momofarm
    hi, I'd like to find a google/facebook login implementation for expressjs, I found that Google and facebook has its own implementation, but also there is another lib call passportjs,
    Should I use passportjs or use google/fb own implementation?
    James Pickard
    @euoia
    Hi @momofarm - I don't have any experience on this but my understanding is that passportjs is fairly popular, so you should find good support for it. It's probably easier than integrating with the Google and Facebook implementations separately?
    Tim Chen
    @momofarm
    I'm thinking about using auth0, since I am a one man dev and don't have much budget on user management........
    gnubyte
    @gnubyte
    morning folks, is there a way to create an object in expressJS Middleware then access it down in a controller/route?
    James Pickard
    @euoia
    @gnubyte you can attach it to the request object in a middleware
    you can set arbitrary values on the request object which are then accessible to later routes and middleware
    A pattern I sometimes use is to attach a log object with info, debug, etc functions to the request object, that logs whatever you give it prefixed with a request ID
    Jim H
    @luckyl2000:matrix.org
    [m]
    don't have any experience in any sort of online/web development. I came up with an idea that I personally think is great in regard to the target audience it serves. I don't know if I should vividly share it on here but I would like to discuss the possibility of this online tool or service. I am looking to discuss this with someone familiar with the pharmaceutical world.
    can someone help or point me in the correct direction?