A library of commonly-needed promise shims.