Skip to content

Commit 61ac5ad

Browse files
committed
translate(reference): API legacy di React index
Traduce la pagina indice legacy, inclusa createFactory nelle API rimosse. Signed-off-by: Alessandro De Blasis <alex@deblasis.net>
1 parent edca99a commit 61ac5ad

2 files changed

Lines changed: 27 additions & 20 deletions

File tree

Lines changed: 26 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,42 @@
11
---
2-
title: "Legacy React APIs"
2+
title: "API legacy di React"
3+
translationStatus: ai-draft
34
---
45

6+
<Note>
7+
8+
Questa pagina è stata tradotta automaticamente e supervisionata da un maintainer. Un'ulteriore revisione da parte della community sarebbe comunque utile. [Migliora questa traduzione](https://github.com/reactjs/it.react.dev/edit/main/src/content/reference/react/legacy.md).
9+
10+
</Note>
11+
512
<Intro>
613

7-
These APIs are exported from the `react` package, but they are not recommended for use in newly written code. See the linked individual API pages for the suggested alternatives.
14+
Queste API sono esportate dal pacchetto `react`, ma non sono consigliate per il codice scritto ex novo. Consulta le singole pagine delle API collegate per le alternative suggerite.
815

916
</Intro>
1017

1118
---
1219

13-
## Legacy APIs {/*legacy-apis*/}
20+
## API legacy {/*legacy-apis*/}
1421

15-
* [`Children`](/reference/react/Children) lets you manipulate and transform the JSX received as the `children` prop. [See alternatives.](/reference/react/Children#alternatives)
16-
* [`cloneElement`](/reference/react/cloneElement) lets you create a React element using another element as a starting point. [See alternatives.](/reference/react/cloneElement#alternatives)
17-
* [`Component`](/reference/react/Component) lets you define a React component as a JavaScript class. [See alternatives.](/reference/react/Component#alternatives)
18-
* [`createElement`](/reference/react/createElement) lets you create a React element. Typically, you'll use JSX instead.
19-
* [`createRef`](/reference/react/createRef) creates a ref object which can contain arbitrary value. [See alternatives.](/reference/react/createRef#alternatives)
20-
* [`forwardRef`](/reference/react/forwardRef) lets your component expose a DOM node to parent component with a [ref.](/learn/manipulating-the-dom-with-refs)
21-
* [`isValidElement`](/reference/react/isValidElement) checks whether a value is a React element. Typically used with [`cloneElement`.](/reference/react/cloneElement)
22-
* [`PureComponent`](/reference/react/PureComponent) is similar to [`Component`,](/reference/react/Component) but it skip re-renders with same props. [See alternatives.](/reference/react/PureComponent#alternatives)
22+
* [`Children`](/reference/react/Children) ti permette di manipolare e trasformare il JSX ricevuto come prop `children`. [Vedi alternative.](/reference/react/Children#alternatives)
23+
* [`cloneElement`](/reference/react/cloneElement) ti permette di creare un elemento React usando un altro elemento come punto di partenza. [Vedi alternative.](/reference/react/cloneElement#alternatives)
24+
* [`Component`](/reference/react/Component) ti permette di definire un componente React come classe JavaScript. [Vedi alternative.](/reference/react/Component#alternatives)
25+
* [`createElement`](/reference/react/createElement) ti permette di creare un elemento React. In genere userai JSX.
26+
* [`createRef`](/reference/react/createRef) crea un oggetto ref che può contenere un valore arbitrario. [Vedi alternative.](/reference/react/createRef#alternatives)
27+
* [`forwardRef`](/reference/react/forwardRef) permette al tuo componente di esporre un nodo DOM al componente padre con un [ref.](/learn/manipulating-the-dom-with-refs)
28+
* [`isValidElement`](/reference/react/isValidElement) verifica se un valore è un elemento React. Tipicamente usato con [`cloneElement`.](/reference/react/cloneElement)
29+
* [`PureComponent`](/reference/react/PureComponent) è simile a [`Component`,](/reference/react/Component) ma salta le ri-renderizzazioni con le stesse props. [Vedi alternative.](/reference/react/PureComponent#alternatives)
2330

2431
---
2532

26-
## Removed APIs {/*removed-apis*/}
33+
## API rimosse {/*removed-apis*/}
2734

28-
These APIs were removed in React 19:
35+
Queste API sono state rimosse in React 19:
2936

30-
* [`createFactory`](https://18.react.dev/reference/react/createFactory): use JSX instead.
31-
* Class Components: [`static contextTypes`](https://18.react.dev//reference/react/Component#static-contexttypes): use [`static contextType`](#static-contexttype) instead.
32-
* Class Components: [`static childContextTypes`](https://18.react.dev//reference/react/Component#static-childcontexttypes): use [`static contextType`](#static-contexttype) instead.
33-
* Class Components: [`static getChildContext`](https://18.react.dev//reference/react/Component#getchildcontext): use [`Context`](/reference/react/createContext#provider) instead.
34-
* Class Components: [`static propTypes`](https://18.react.dev//reference/react/Component#static-proptypes): use a type system like [TypeScript](https://www.typescriptlang.org/) instead.
35-
* Class Components: [`this.refs`](https://18.react.dev//reference/react/Component#refs): use [`createRef`](/reference/react/createRef) instead.
37+
* [`createFactory`](https://18.react.dev/reference/react/createFactory): usa JSX invece.
38+
* Class Components: [`static contextTypes`](https://18.react.dev//reference/react/Component#static-contexttypes): usa [`static contextType`](#static-contexttype) invece.
39+
* Class Components: [`static childContextTypes`](https://18.react.dev//reference/react/Component#static-childcontexttypes): usa [`static contextType`](#static-contexttype) invece.
40+
* Class Components: [`static getChildContext`](https://18.react.dev//reference/react/Component#getchildcontext): usa [`Context`](/reference/react/createContext#provider) invece.
41+
* Class Components: [`static propTypes`](https://18.react.dev//reference/react/Component#static-proptypes): usa un sistema di tipi come [TypeScript](https://www.typescriptlang.org/) invece.
42+
* Class Components: [`this.refs`](https://18.react.dev//reference/react/Component#refs): usa [`createRef`](/reference/react/createRef) invece.

src/sidebarReference.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -539,7 +539,7 @@
539539
"sectionHeader": "Legacy APIs"
540540
},
541541
{
542-
"title": "Legacy React APIs",
542+
"title": "API legacy di React",
543543
"path": "/reference/react/legacy",
544544
"routes": [
545545
{

0 commit comments

Comments
 (0)