react/packages/react
Dennis Moradkhani 4b877b6c66
Updated copyright text to Copyright (c) Meta Platforms, Inc. and its … (#26830)
…affiliates.

## Summary

There were 8 different places where the copyright comment was wrong.
Rewrote from "Copyright (c) Facebook, Inc. and its affiliates." to
"Copyright (c) Meta Platforms, Inc. and its affiliates."

## How did you test this change?
No code was changed. Comment was still a comment after changes.

Co-authored-by: Dennis Moradkhani <denmo530@student.liu.se>
2023-05-19 17:52:17 -07:00
..
npm Remove public export for unstable-shared-subset.js (#23261) 2022-02-22 20:03:51 -05:00
src Updated copyright text to Copyright (c) Meta Platforms, Inc. and its … (#26830) 2023-05-19 17:52:17 -07:00
README.md chore: update links of docs and api (#26455) 2023-03-22 12:56:18 +01:00
index.classic.fb.js useOptimisticState -> useOptimistic (#26772) 2023-05-03 14:26:00 -04:00
index.experimental.js useOptimisticState -> useOptimistic (#26772) 2023-05-03 14:26:00 -04:00
index.js useOptimisticState -> useOptimistic (#26772) 2023-05-03 14:26:00 -04:00
index.modern.fb.js useOptimisticState -> useOptimistic (#26772) 2023-05-03 14:26:00 -04:00
index.stable.js Update cache() and use() to the canary aka next channel (#25502) 2022-10-23 23:20:52 -04:00
jsx-dev-runtime.js [Codemod] Update copyright header to Meta (#25315) 2022-10-18 11:19:24 -04:00
jsx-runtime.js [Codemod] Update copyright header to Meta (#25315) 2022-10-18 11:19:24 -04:00
package.json bump versions for next release (#24725) 2022-06-14 13:24:00 -07:00
react.shared-subset.js Updated Copyright comment from Facebook to Meta (#26833) 2023-05-19 17:51:44 -07:00

README.md

react

React is a JavaScript library for creating user interfaces.

The react package contains only the functionality necessary to define React components. It is typically used together with a React renderer like react-dom for the web, or react-native for the native environments.

Note: by default, React will be in development mode. The development version includes extra warnings about common mistakes, whereas the production version includes extra performance optimizations and strips all error messages. Don't forget to use the production build when deploying your application.

Usage

import { useState } from 'react';
import { createRoot } from 'react-dom/client';

function Counter() {
  const [count, setCount] = useState(0);
  return (
    <>
      <h1>{count}</h1>
      <button onClick={() => setCount(count + 1)}>
        Increment
      </button>
    </>
  );
}

const root = createRoot(document.getElementById('root'));
root.render(<Counter />);

Documentation

See https://react.dev/

API

See https://react.dev/reference/react