[cors] Add delegate function and change owner#25177
[cors] Add delegate function and change owner#25177RyanCavanaugh merged 2 commits intoDefinitelyTyped:masterfrom pluma:fix-cors
Conversation
|
@pluma Thank you for submitting this PR! Because this PR doesn't have any code reviewers, a DefinitelyTyped maintainer will be reviewing it in the next few days once the Travis CI build passes. In the meantime, if the build fails or a merge conflict occurs, I'll let you know. Have a nice day! |
|
Ping @mihhail-lapushkin |
|
I am totally out of TS community for years already. I don't know how to react to these requests. Is there a way I can resign the "ownership" of these modules? |
|
@mihhail-lapushkin you can submit a PR to remove your name from the header |
|
I can take over ownership of this one if you want. I don't know what other typings you contributed but maybe I can take care of some of those for you too?
|
|
@mihhail-lapushkin I've added a commit to remove you from this module. I'm not familiar with tea-merge, though, and I think it's unrelated to this one. @RyanCavanaugh should I file a separate PR on @mihhail-lapushkin's behalf to remove him from tea-merge and leave it as unowned for the time being? |
|
@pluma sounds fine by me. Please link to this PR from it since the next maintainer who sees it will otherwise reject it. |
|
@RyanCavanaugh Can we get this PR merged then? I've removed him in this one and the linting is passing. I am also using the changes successfully as we speak. @mihhail-lapushkin I've created PR #25223 to remove you from tea-merge as you requested. |
|
btw, I'm confused that the type declaration declares a |
|
@pluma the namespace is necessary in this case because the module exports a combination of a function and properties |
|
🌟 🎈 🎉 🏆 🎂 ✨ ⭐️ Congratulations on your first DefinitelyTyped contribution! Thanks for helping out Mihhail as well. 🌟 🎈 🎉 🏆 🎂 ✨ ⭐️ |
|
Yay, thanks for the guidance 🎉 |
Please fill in this template.
npm test.)npm run lint package-name(ortscif notslint.jsonis present).If changing an existing definition:
tslint.jsoncontaining{ "extends": "dtslint/dt.json" }.This seems to be an unintentional omission. The delegate has been supported as early as v1.0 and the typings claim to be compatible with v2.8 which still supports this.
Basically instead of providing the config synchronously, one can provide a delegate function which takes a request object and a callback and passes the configuration on a per request basis. This is probably a rare use case but certainly supported by the library.