mongo-express icon indicating copy to clipboard operation
mongo-express copied to clipboard

use native promises instead of bluebird

Open dungmv opened this issue 4 years ago • 2 comments

Native Promises have been stable, so you should replace bluebird by native promises

dungmv avatar Oct 26 '21 07:10 dungmv

Hi! From doing a quick search it looks like most usage of bluebird is to wrap and unwrap promises for interaction with callbacks. https://github.com/mongo-express/mongo-express/search?q=bluebird

I'd love to hear your thoughts about why making the change and the benefit we will have by making our own wrappers/unwrappers vs just using bluebird?

dozoisch avatar Oct 26 '21 18:10 dozoisch

I think Native Promises to easy to maintain and upgrade, standard code is easy to read and write for many developers. it helps anyone who wants to contribute takes less effort. Almost library support promises, so wrap and unwrap callback is unnecessary

dungmv avatar Oct 27 '21 01:10 dungmv

@dungmv I agree with you. Bluebird is removed with #884

rtritto avatar Sep 10 '22 21:09 rtritto