I’m thinking of implementing promises into the Meteor methods and in the Accounts methods. I’ve been digging trough the core packages to see if and how and it seems do-able.
Any support for this? If that’s a yes, I will make a PR some time in the future…
I have been working with methods returning promises for a while and has been great. Having support for it on the core would be nice.
Actually I though about adding this feature to the validated method package too, but I really dont export methods I call them by name, so I never did it.
I think that this would lower the barrier between non Meteor developers. Its a small step into the direction of not having to use Fibers on the serverside aswell. I find having to install a package just to use Methods with promises 1 extra step too much (a small one though).
A lot of libraries seem to provide a promisified version of a function out of the box, first one to pop into my mind would be AWS SDK.
I think it would be nice, and I agree I’m not a fan of finding, evaluating and learning a random package to achieve this.
However, I’d recommend you first make a feature request here https://github.com/meteor/meteor-feature-requests unless there is one already? Maybe start working on the PR only after some green light has been indicated by the core team.