Movatterモバイル変換


[0]ホーム

URL:


We want to hear from you!Take our 2021 Community Survey!
This site is no longer updated.Go to react.dev

CDN Links

These docs are old and won’t be updated. Go toreact.dev for the new React docs.

SeeAdd React to an Existing Project for the recommended ways to add React.

Both React and ReactDOM are available over a CDN.

<scriptcrossoriginsrc="https://unpkg.com/react@18/umd/react.development.js"></script><scriptcrossoriginsrc="https://unpkg.com/react-dom@18/umd/react-dom.development.js"></script>

The versions above are only meant for development, and are not suitable for production. Minified and optimized production versions of React are available at:

<scriptcrossoriginsrc="https://unpkg.com/react@18/umd/react.production.min.js"></script><scriptcrossoriginsrc="https://unpkg.com/react-dom@18/umd/react-dom.production.min.js"></script>

To load a specific version ofreact andreact-dom, replace18 with the version number.

Why thecrossorigin Attribute?

If you serve React from a CDN, we recommend to keep thecrossorigin attribute set:

<scriptcrossoriginsrc="..."></script>

We also recommend to verify that the CDN you are using sets theAccess-Control-Allow-Origin: * HTTP header:

Access-Control-Allow-Origin: *

This enables a bettererror handling experience in React 16 and later.

Is this page useful?Edit this page

[8]ページ先頭

©2009-2025 Movatter.jp