Express Middleware... Async vs. Not?

I just had a question that may have already been asked before, but…

I’m coming back to development after taking a hiatus for a while, and was just reading through the docs for apollo-express-server and I see that now it’s using async/await when it didn’t before.

I was able to successfully run my old boilerplate code (before this change) and it’s fine and working, so…is there a benefit to switching over to this new method of initializing Express/Apollo via async/await/Promises?

Wanted to ask about it now before I started my first project with it, so if there -is- a good reason, I can switch over now.

@czbaker for a full explanation of why these changes were made, see:

Thanks! That makes sense. I’ll definitely switch over then.

Appreciate the explanation/response!

1 Like