defer

defer

This utility allows you to defer values returned from loaders by passing promises instead of resolved values.

function loader() {
  let product = await getProduct();
  let reviews = getProductReviews();
  return defer({ product, reviews });
}

See the Deferred Guide for more information.

Docs and examples CC 4.0