Commit Graph

6896 Commits

Author SHA1 Message Date
Ricky
2a57a4e379 Update src/content/blog/2025/10/16/react-conf-2025-recap.md 2025-10-16 16:12:12 -04:00
Matt Carroll
5649b55372 Add 'thanks' section and formatting edits 2025-10-16 12:58:55 -07:00
Rick Hanlon
88cc738a1e revamp 2025-10-16 11:54:19 -04:00
Matt Carroll
1bf4693e3e Fix links and formatting 2025-10-15 09:06:31 -07:00
Matt Carroll
794173a7f9 Fix X links 2025-10-15 02:07:29 -07:00
Matt Carroll
71aee7c2e7 Add React Conf 2025 recap blog post 2025-10-15 01:41:08 -07:00
Sébastien Lorber
a677ba3424 Fragment refs - Remove unused ref from focus fragment example (#8056) 2025-10-13 12:39:04 +02:00
Dominik Dorfmeister
02ecdeda7c Update caveats for Activity rendering behavior (#8067)
Co-authored-by: Sebastian "Sebbie" Silbermann <sebastian.silbermann@vercel.com>
2025-10-13 11:13:24 +02:00
dan
0d05d9b6ef Revert "Reorder compiler post a bit (#8071)" (#8074)
This reverts commit 6346efd905.
2025-10-11 17:39:53 +01:00
Uladzislau Hramyka
7e24db5f6a fix: correct example link to minified error on /errors index page (#8070) 2025-10-11 16:23:02 +01:00
mdj-uk
16e97fad43 Fix server/client typo in <form> docs (#6627)
* Fix server/client typo in <form> docs

Fixes #6601

* Update form.md

* Update form.md

* Update form.md
2025-10-11 16:09:33 +01:00
dan
6346efd905 Reorder compiler post a bit (#8071) 2025-10-11 16:04:45 +01:00
lauren
be77c2a257 React Compiler v1 (#8065)
Updates our blog posts and docs for React Compiler 1.0
2025-10-10 14:50:27 -04:00
Omoshola E.
ec27355976 Fix grammatical error in ViewTransition documentation (#8068) 2025-10-09 16:35:13 -07:00
lauren
ef80db85df Fix broken tabs (#8063) 2025-10-08 00:38:52 -04:00
lauren
8d73630aa5 Upgrade to stable react compiler (#8058)
Upgrade to latest
2025-10-07 16:22:54 -04:00
Matt Carroll
d9e35047ab Add React Foundation blog post (#8057) 2025-10-07 10:09:43 -07:00
Sebastian "Sebbie" Silbermann
249535378a Bump ViewTransition and Fragment ref docs to canary (#8048) 2025-10-07 08:08:39 -07:00
Sebastian "Sebbie" Silbermann
28e9bd9fa2 Document React's profiling build (#8054) 2025-10-06 13:47:38 -04:00
lauren
11cb6b5915 Clarify eslint-plugin-react-hooks configuration details (#8052)
Updated description of eslint-plugin-react-hooks configuration and preset.
2025-10-03 21:23:21 -04:00
lauren
7b8612ec41 Update eslint-plugin-react-hooks version reference (#8051)
Updates all mentions of eslint-plugin-react-hooks rc and 6.1.0 to refer to the new 6.1.1 which has important bugfixes.
2025-10-03 19:03:28 -04:00
Jack Pope
ae584af4da Add experimental docs for Fragment refs (#8010)
* Add experimental docs for Fragment refs

* Update wording

* Address feedback
2025-10-03 10:35:59 -04:00
Sophie Alpert
775d895c98 fix typo 2025-10-03 03:33:02 -07:00
Sebastian "Sebbie" Silbermann
996ef72c1a Prerender can be aborted in stable (#8039) 2025-10-02 19:24:24 +02:00
Rick Hanlon
07b7a5d999 s/19.3/19.2 2025-10-02 10:27:17 -04:00
Ricky
42037e2dfd Few cleanups for 19.2 (#8046) 2025-10-02 10:06:30 -04:00
dan
9850724eb4 Upgrade sandboxes to 19.2 (#8037)
* Use stable release in demos with HTML output

* Fix Activity sandboxes (#8035)

* Fix Activity sandboxes

* hacky fix

* Revert "Fix Activity sandboxes (#8035)"

This reverts commit f9fd07ca59.

* Bump to 19.2

* cleanup rest of sandpacks

* Pin deps

* Add back package.json with third-party deps

* "^" should be fixed now

* add back package.json for more toastify deps

* fuggin whitespace

* more fuggin whitespace

* fml like fr fr

---------

Co-authored-by: Sebastian Sebbie Silbermann <sebastian.silbermann@vercel.com>
Co-authored-by: Ricky <rickhanlonii@gmail.com>
Co-authored-by: Rick Hanlon <rickhanlonii@meta.com>
2025-10-02 09:58:19 -04:00
Sebastian "Sebbie" Silbermann
37f862a64b Latest release is 19.2 (#8040) 2025-10-02 14:02:23 +02:00
Ricky
f9fd07ca59 Fix Activity sandboxes (#8035)
* Fix Activity sandboxes

* hacky fix
2025-10-01 19:23:34 -04:00
Jack Pope
0a803f61d8 Update eslint-plugin-react-hooks config docs (#8030)
We're updating eslint-plugin-react-hooks with support for useEffectEvent usage and updated configuration options for applying the useEffectEvent and other effect rules to custom effect hooks.

This adds the documentation for the config syntax and adds mention to the useEffectEvent reference page that the linter should be used to ensure proper usage of Effect Events.
2025-10-01 17:55:59 -04:00
Ricky
c3d7560005 Blog post for React 19.2 (#8028)
* wip

* feedback and rm canary stuff

* tweak

* fix json

* more canary stuff

* fix link

* update dates

* update meta description

* Expand performance track section

* adjust linter note

* edit perf tracks down

* edit perf tracks down more

* tweak note

* tweak useEffectEvent

* formatting

* tweaks

* ppr

* rm canary stuff

* fix json

* fix json

* tweaks

* linter note

* nit

* nit

* link

* nit

* ppr

* missing await

* add lint v6

* fix link

---------

Co-authored-by: Dan Abramov <dan.abramov@gmail.com>
2025-10-01 17:42:52 -04:00
Sebastian "Sebbie" Silbermann
dc86f88afe Overview for React Server Performance tracks (#8031) 2025-10-01 21:28:18 +02:00
dan
10e5ad50cf Conditionally deriving state is allowed (#8033) 2025-10-01 20:11:07 +01:00
Ricky
aba6b86772 Docs for partial-prerendering APIs (#7869)
* Init PPR docs

* Overhaul

* Apply suggestions from code review

---------

Co-authored-by: Sebastian Sebbie Silbermann <sebastian.silbermann@vercel.com>
2025-10-01 13:48:16 -04:00
Ruslan Lesiutin
9fddeca99b docs: initial docs for Performance tracks (#7938)
* docs: scaffold docs structure for Performance tracks

* docs: initial draft of Tracks section

* refactor: moved to reference root section and added to the sidebar

* chore: updated to canary and minor changes
2025-10-01 13:34:56 +01:00
Sebastian "Sebbie" Silbermann
3f0235be3d Docs for cacheSignal (#8023)
* Docs for `cacheSignal`

* Apply suggestion from review

Co-authored-by: Sebastian Markbåge <sebastian@calyptus.eu>

* Apply suggestion from review

Co-authored-by: Sebastian Markbåge <sebastian@calyptus.eu>

* Update src/content/reference/react/cacheSignal.md

---------

Co-authored-by: Sebastian Markbåge <sebastian@calyptus.eu>
2025-10-01 08:20:52 -04:00
Karl Horky
c60922ff73 Fix incorrect negative in use-memo intro (#8027) 2025-09-30 21:01:55 -04:00
Jack Pope
49c2d26722 Update useEffectEvent docs for canary (#8025)
* Update useEffectEvent docs for canary

* Clean up prefixed imports

* Fix import

* Update blog post link
2025-09-28 11:36:27 -04:00
Radoš Milićev
1b20061b10 Fix value wrongly formatted as code in useDeferredValue.md (#8024) 2025-09-26 18:15:37 +02:00
Eugene Choi
790625fd22 Fix ViewTransition examples (#7999)
* Fix view transition example

* Empty commit

* Fix fullscreen example
2025-09-23 17:25:52 -04:00
Radoš Milićev
170e5b904a Remove unnecessary spaces from useCallback.md (#8006) 2025-09-23 09:58:55 +02:00
Ricky
c8211fc21e Add RC badge to RC-only lint rules (#8005) 2025-09-22 10:18:10 -04:00
lauren
366b5fbdad Add new eslint rule reference docs (#7986)
Adds new docs for our new eslint rules.
2025-09-19 16:19:48 -04:00
lauren
c15e20f811 Install eslint-local-rules as postinstall (#7993)
For local dev and CI we want to have the eslint-local-rules running, so let's make sure both have their dependencies installed. We don't use a monorepo setup here, which is why they're currently setup as a two completely independent yarn workspaces.
2025-09-19 11:19:36 -04:00
lauren
730d045c71 Restore lint corrections from #7989 (#7997)
* Ignore braces when building Sandpack file map

Previously, `createFileMap` split the MDX meta string on spaces and assumed the first token was the filename. Once we prefixed code fences with `{expectedErrors: ...}`, it would incorrectly parse the meta and crash.

This PR updates createFileMap to skip tokens in the meta containing a start and end brace pair (using a stack to ensure we close on the correct brace) while tokenizing the meta string as expected.

Test plan: pages reported in #7994 no longer crash on the next PR

Closes #7994

* Restore lint corrections from #7989

Reverts the revert now that we've fixed the bug. These pages should no longer crash:

https://react-dev-git-pr7997-fbopensource.vercel.app/learn/referencing-values-with-refs
https://react-dev-git-pr7997-fbopensource.vercel.app/learn/synchronizing-with-effects
https://react-dev-git-pr7997-fbopensource.vercel.app/learn/separating-events-from-effects
https://react-dev-git-pr7997-fbopensource.vercel.app/learn/removing-effect-dependencies
https://react-dev-git-pr7997-fbopensource.vercel.app/learn/you-might-not-need-an-effect
2025-09-18 19:18:19 -04:00
lauren
f369f3efdf Ignore braces when building Sandpack file map (#7996)
Previously, `createFileMap` split the MDX meta string on spaces and assumed the first token was the filename. Once we prefixed code fences with `{expectedErrors: ...}`, it would incorrectly parse the meta and crash.

This PR updates createFileMap to skip tokens in the meta containing a start and end brace pair (using a stack to ensure we close on the correct brace) while tokenizing the meta string as expected.

Test plan: pages reported in #7994 no longer crash on the next PR

Closes #7994
2025-09-18 19:18:09 -04:00
lauren
2a9ef2d173 Revert "fix compiler errors (#7989)" (#7995)
This reverts commit 5cc9b7ba31.
2025-09-18 18:06:43 -04:00
lauren
5cc9b7ba31 fix compiler errors (#7989)
* Add local eslint rule to validate markdown codeblocks with React Compiler

In https://github.com/facebook/react/pull/34462 for example, we found an issue where the compiler was incorrectly validating an example straight from the docs.

In order to find more issues like this + also provide more feedback to doc authors on valid/invalid patterns, this PR adds a new local eslint rule which validates all markdown codeblocks containing components/hooks with React Compiler. An autofixer is also provided.

To express that a codeblock has an expected error, we can use the following metadata:

```ts
// pseudo type def
type MarkdownCodeBlockMetadata = {
    expectedErrors?: {
      'react-compiler'?: number[];
    };
  };
```

and can be used like so:

````
```js {expectedErrors: {'react-compiler': [4]}}
//  setState directly in render
function Component({value}) {
  const [count, setCount] = useState(0);
  setCount(value); // error on L4
  return <div>{count}</div>;
}
```
````

Because this is defined as a local rule, we don't have the same granular reporting that `eslint-plugin-react-hooks` yet. I can look into that later but for now this first PR just sets us up with something basic.

* fix compiler errors

I went through the list of existing errors and tried to separate the expected errors from those that seem to be flagging unexpected issues.  In particular, our effects validations are flagging patterns that our own docs examples use. I added todos for these and will follow up later.
2025-09-18 15:32:27 -04:00
lauren
b6a32d1e0e Add local eslint rule to validate markdown codeblocks with React Compiler (#7988)
In https://github.com/facebook/react/pull/34462 for example, we found an issue where the compiler was incorrectly validating an example straight from the docs.

In order to find more issues like this + also provide more feedback to doc authors on valid/invalid patterns, this PR adds a new local eslint rule which validates all markdown codeblocks containing components/hooks with React Compiler. An autofixer is also provided.

To express that a codeblock has an expected error, we can use the following metadata:

```ts
// pseudo type def
type MarkdownCodeBlockMetadata = {
    expectedErrors?: {
      'react-compiler'?: number[];
    };
  };
```

and can be used like so:

````
```js {expectedErrors: {'react-compiler': [4]}}
//  setState directly in render
function Component({value}) {
  const [count, setCount] = useState(0);
  setCount(value); // error on L4
  return <div>{count}</div>;
}
```
````

Because this is defined as a local rule, we don't have the same granular reporting that `eslint-plugin-react-hooks` yet. I can look into that later but for now this first PR just sets us up with something basic.
2025-09-18 15:32:18 -04:00
lauren
bd03b86c02 Update copyright on all files (#7992)
* Add copyright script

Copied over our copyright script from the react repo. I made a small fix to handle shebangs.

* Update copyright on all files

Run the script.
2025-09-18 14:42:36 -04:00