Skip to content

Version Packages (beta)#4164

Merged
davidkpiano merged 1 commit intonextfrom
changeset-release/next
Jul 28, 2023
Merged

Version Packages (beta)#4164
davidkpiano merged 1 commit intonextfrom
changeset-release/next

Conversation

@github-actions
Copy link
Copy Markdown
Contributor

This PR was opened by the Changesets release GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to next, this PR will be updated.

⚠️⚠️⚠️⚠️⚠️⚠️

next is currently in pre mode so this branch has prereleases rather than normal releases. If you want to exit prereleases, run changeset pre exit on next.

⚠️⚠️⚠️⚠️⚠️⚠️

Releases

xstate@5.0.0-beta.20

Major Changes

  • #4036 e2440f0b1 Thanks @davidkpiano! - Actor types can now be specified in the .types property of createMachine:

    const fetcher = fromPromise(() => fetchUser());
    
    const machine = createMachine({
      types: {} as {
        actors: {
          src: 'fetchData'; // src name (inline behaviors ideally inferred)
          id: 'fetch1' | 'fetch2'; // possible ids (optional)
          logic: typeof fetcher;
        };
      },
      invoke: {
        src: 'fetchData', // strongly typed
        id: 'fetch2', // strongly typed
        onDone: {
          actions: ({ event }) => {
            event.output; // strongly typed as { result: string }
          }
        },
        input: { foo: 'hello' } // strongly typed
      }
    });

Minor Changes

  • #4157 31eb5f8a1 Thanks @Valkendorm! - Merge sendBack and receive with other properties of fromCallback logic creator.

    const callbackLogic = fromCallback(({ input, system, self, sendBack, receive }) => { ... });

@github-actions github-actions Bot force-pushed the changeset-release/next branch from c1bf18d to d66c5cc Compare July 28, 2023 12:28
@codesandbox-ci
Copy link
Copy Markdown

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit d66c5cc:

Sandbox Source
XState Example Template Configuration
XState React Template Configuration

@davidkpiano davidkpiano merged commit f0694cb into next Jul 28, 2023
@davidkpiano davidkpiano deleted the changeset-release/next branch July 28, 2023 13:59
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