Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: defer.await() #4

Merged
merged 10 commits into from
Dec 15, 2022
Merged

feat: defer.await() #4

merged 10 commits into from
Dec 15, 2022

Conversation

charlypoly
Copy link
Contributor

@charlypoly charlypoly commented Nov 30, 2022

Get the result of a Defer function execution.

The caller receives a Promise that is pending function execution.

import { defer } from '@defer.run/client'

async function importContactsFromIntercom() {
   // ...
}

export default defer.await(importContactsFromIntercom)

Todo

  • better error handling on execution result
  • refactor when API is ready
  • manual QA with canary on defer.demo

@charlypoly charlypoly self-assigned this Nov 30, 2022
@changeset-bot
Copy link

changeset-bot bot commented Nov 30, 2022

🦋 Changeset detected

Latest commit: 10c07f7

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@defer.run/client Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions
Copy link
Contributor

github-actions bot commented Nov 30, 2022

🚀 Snapshot Release (alpha)

The latest changes of this PR are available as alpha on npm (based on the declared changesets):

Package Version Info
@defer.run/client 0.1.0-alpha-20221213110027-d68d1a8 npm ↗︎ unpkg ↗︎

@charlypoly charlypoly merged commit c213e24 into master Dec 15, 2022
@charlypoly charlypoly deleted the feat/defer.await branch December 15, 2022 17:20
@github-actions github-actions bot mentioned this pull request Dec 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant