Skip to content

docs(getting-started): restore the React getting started, modernized - #770

Merged
rolljee merged 1 commit into
7-devfrom
docs/590-restore-react-getting-started
Sep 18, 2026
Merged

rolljee merged 1 commit into
7-devfrom
docs/590-restore-react-getting-started

Conversation

@rolljee

@rolljee rolljee commented Sep 18, 2026

Copy link
Copy Markdown
Member

Fixes kuzzleio/documentation#590.

Context

/sdk/js/7/getting-started/react/standalone and /sdk/js/7/getting-started/react/with-redux have been 404ing since 2e439ab ("remove Getting started since they are all outdated", Aug 2023). Nothing in the docs links to them anymore, but external links still do — hence the issue.

What this does

Restores the two React pages, rewritten against a current stack rather than reinstated as they were:

  • Vite instead of create-react-app, Node 20 instead of Node 8
  • function components and hooks instead of class components
  • Redux Toolkit (createSlice / createAsyncThunk) instead of hand-written action types, switch reducers and redux-saga
  • the realtime subscription is opened before the history is fetched and closed on unmount, so no message can slip through between the two calls and Strict Mode doesn't leak a room
  • sending a message no longer mutates local state — it comes back through the notification, same path as everyone else's

Snippets are plain files, like the existing node-js and raw-web pages, instead of symlinks into a full CRA app carrying its own Cypress suite. The .react/ and .react-native/ fixture apps and the .ci/test-docs.sh job are not restored.

react-native is deliberately left out: Expo has moved far enough that it needs its own rewrite, not a port.

Verification

Built locally with the framework repo (vuepress build src with only sdk-javascript-7 installed — there is no doc build in PR CI):

  • build succeeds, frontmatter lint clean
  • both pages render, all <<< snippets inline correctly
  • sidebar shows Getting Started → React → Standalone / React with Redux

🤖 Generated with Claude Code

The React getting started pages were removed in 2e439ab because they
were outdated, which left /sdk/js/7/getting-started/react/* answering a
404 to every inbound link (#590).

They are restored here, rewritten against a current stack:

- Vite instead of create-react-app, Node 20 instead of Node 8
- function components and hooks instead of class components
- Redux Toolkit instead of hand-written actions/reducers + redux-saga
- the realtime subscription is opened before the history is fetched and
  is closed on unmount, so no message is lost and Strict Mode does not
  leak a room

Snippets are plain files, like the node-js and raw-web pages, instead of
symlinks into a full CRA application with its own Cypress suite.

react-native is deliberately left out.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@rolljee
rolljee merged commit e2378e2 into 7-dev Sep 18, 2026
12 checks passed
@rolljee
rolljee deleted the docs/590-restore-react-getting-started branch September 18, 2026 18:28
@rolljee rolljee mentioned this pull request Sep 30, 2026
@kuzzle

kuzzle commented Sep 30, 2026

Copy link
Copy Markdown
Contributor

🎉 This PR is included in version 7.18.0-beta.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

@kuzzle

kuzzle commented Sep 30, 2026

Copy link
Copy Markdown
Contributor

🎉 This PR is included in version 7.18.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants