Skip to content
This repository was archived by the owner on Jan 14, 2020. It is now read-only.
This repository was archived by the owner on Jan 14, 2020. It is now read-only.

Async JS Guidelines #180

Open
Open
@gaboesquivel

Description

@gaboesquivel

At some point it will be good to define the Origin's async JS code style / guidelines.

Currently promises and async/await a being used. I personally tend to prefer await/async for readability, it usually requires less identation and less "cleverness" than promises.

For working with promises this is a great resource, has modular package for each need and with good feats like controlling concurrency on Promise.all https://github.com/sindresorhus/promise-fun
Bluebird is nice too.

I get what we care about right now is functionality, however standards first is nice too have. It has it's maintainability benefits.

I've also found that error handling is less complex with try/catch await/async style than with chained promises .error() callbacks.

This is good lecture https://zeit.co/blog/async-and-await

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions