Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 0 additions & 7 deletions .changeset/stable-useflow-actions.md

This file was deleted.

11 changes: 11 additions & 0 deletions docs/components/ChangelogContent.mdx
Original file line number Diff line number Diff line change
@@ -1,3 +1,14 @@
## 2026.07.07

Memoize the action functions returned by `useFlow` and `useStepFlow` so their references stay stable across renders. [`91c433c`](https://github.com/daangn/stackflow/commit/91c433cc2f60462c59f6e1b990bc8339d7fbbc00)

Previously these hooks rebuilt their action object (`push`/`replace`/`pop`, `pushStep`/`replaceStep`/`popStep`) on every render, giving the returned functions a new reference each time. Since the underlying core actions are already a stable reference, the returned actions are now memoized on them (the same approach `usePrepare` already uses). This keeps the functions referentially stable when placed in `useEffect`/`useCallback` dependency arrays, avoiding unnecessary re-runs.

Released packages:
- 📦 [@stackflow/react@2.1.1](https://npmjs.com/package/@stackflow/react/v/2.1.1)

---

## 2026.06.08

Expose `prepare` on the `stackflow()` output to preload an activity's component chunk and data loader from outside the React render tree (e.g. at app bootstrap, before the first render), without depending on React Context. [`510a287`](https://github.com/daangn/stackflow/commit/510a28705ef44dd153cef895cf88a341eb351ad3)
Expand Down
8 changes: 8 additions & 0 deletions integrations/react/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# @stackflow/react

## 2.1.1

### Patch Changes

- 91c433c: Memoize the action functions returned by `useFlow` and `useStepFlow` so their references stay stable across renders.

Previously these hooks rebuilt their action object (`push`/`replace`/`pop`, `pushStep`/`replaceStep`/`popStep`) on every render, giving the returned functions a new reference each time. Since the underlying core actions are already a stable reference, the returned actions are now memoized on them (the same approach `usePrepare` already uses). This keeps the functions referentially stable when placed in `useEffect`/`useCallback` dependency arrays, avoiding unnecessary re-runs.

## 2.1.0

### Minor Changes
Expand Down
2 changes: 1 addition & 1 deletion integrations/react/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@stackflow/react",
"version": "2.1.0",
"version": "2.1.1",
"repository": {
"type": "git",
"url": "https://github.com/daangn/stackflow.git",
Expand Down
Loading