├── .nvmrc
├── .watchmanconfig
├── .gitattributes
├── fixtures
├── art
│ ├── .gitignore
│ ├── README.md
│ └── app.js
├── flight
│ ├── .nvmrc
│ ├── src
│ │ ├── cjs
│ │ │ ├── package.json
│ │ │ ├── Counter3.js
│ │ │ └── Note.js
│ │ ├── style.css
│ │ ├── Counter2.js
│ │ ├── Container.js
│ │ ├── ServerState.js
│ │ ├── Dynamic.js
│ │ ├── ShowMore.js
│ │ └── ErrorBoundary.js
│ ├── config
│ │ └── package.json
│ ├── loader
│ │ └── package.json
│ ├── scripts
│ │ └── package.json
│ ├── server
│ │ └── package.json
│ ├── public
│ │ └── favicon.ico
│ └── .gitignore
├── flight-esm
│ ├── .nvmrc
│ ├── loader
│ │ └── package.json
│ ├── server
│ │ └── package.json
│ ├── src
│ │ ├── style.css
│ │ └── ServerState.js
│ ├── public
│ │ └── favicon.ico
│ └── .gitignore
├── packaging
│ ├── rjs
│ │ ├── dev
│ │ │ ├── .gitignore
│ │ │ ├── index.html
│ │ │ ├── input.js
│ │ │ ├── package.json
│ │ │ ├── yarn.lock
│ │ │ └── config.js
│ │ └── prod
│ │ │ ├── .gitignore
│ │ │ ├── index.html
│ │ │ ├── input.js
│ │ │ ├── package.json
│ │ │ ├── yarn.lock
│ │ │ └── config.js
│ ├── webpack
│ │ ├── dev
│ │ │ ├── .gitignore
│ │ │ ├── index.html
│ │ │ ├── input.js
│ │ │ ├── package.json
│ │ │ └── config.js
│ │ └── prod
│ │ │ ├── .gitignore
│ │ │ ├── index.html
│ │ │ ├── input.js
│ │ │ └── package.json
│ ├── browserify
│ │ ├── dev
│ │ │ ├── .gitignore
│ │ │ ├── index.html
│ │ │ ├── input.js
│ │ │ └── package.json
│ │ └── prod
│ │ │ ├── .gitignore
│ │ │ ├── index.html
│ │ │ ├── input.js
│ │ │ └── package.json
│ ├── webpack-alias
│ │ ├── dev
│ │ │ ├── .gitignore
│ │ │ ├── index.html
│ │ │ ├── input.js
│ │ │ ├── package.json
│ │ │ └── config.js
│ │ └── prod
│ │ │ ├── .gitignore
│ │ │ ├── index.html
│ │ │ ├── input.js
│ │ │ ├── package.json
│ │ │ └── config.js
│ ├── systemjs-builder
│ │ ├── dev
│ │ │ ├── .gitignore
│ │ │ ├── index.html
│ │ │ ├── input.js
│ │ │ ├── package.json
│ │ │ ├── build.js
│ │ │ └── config.js
│ │ └── prod
│ │ │ ├── .gitignore
│ │ │ ├── index.html
│ │ │ ├── input.js
│ │ │ ├── package.json
│ │ │ ├── build.js
│ │ │ └── config.js
│ └── brunch
│ │ ├── dev
│ │ ├── .gitignore
│ │ ├── index.html
│ │ ├── config.js
│ │ ├── input.js
│ │ ├── app
│ │ │ └── initialize.js
│ │ └── package.json
│ │ └── prod
│ │ ├── .gitignore
│ │ ├── index.html
│ │ ├── config.js
│ │ ├── input.js
│ │ ├── app
│ │ └── initialize.js
│ │ └── package.json
├── nesting
│ ├── .eslintignore
│ ├── src
│ │ ├── index.js
│ │ ├── shared
│ │ │ ├── ThemeContext.js
│ │ │ ├── Clock.js
│ │ │ └── useTime.js
│ │ ├── legacy
│ │ │ └── package.json
│ │ ├── modern
│ │ │ ├── package.json
│ │ │ └── index.js
│ │ └── store.js
│ ├── .env
│ └── public
│ │ └── index.html
├── fiber-debugger
│ ├── .env
│ ├── public
│ │ ├── favicon.ico
│ │ └── index.html
│ ├── src
│ │ ├── index.js
│ │ └── index.css
│ ├── .gitignore
│ └── package.json
├── devtools
│ └── scheduling-profiler
│ │ ├── .gitignore
│ │ └── index.html
├── eslint
│ ├── proxy
│ │ └── package.json
│ ├── watch.sh
│ ├── package.json
│ ├── README.md
│ └── .eslintrc.json
├── dom
│ ├── public
│ │ ├── test.mp4
│ │ └── favicon.ico
│ ├── src
│ │ ├── index.js
│ │ └── components
│ │ │ ├── App.js
│ │ │ └── Fixture.js
│ └── README.md
├── ssr
│ ├── public
│ │ ├── favicon.ico
│ │ └── index.html
│ └── src
│ │ ├── index.js
│ │ └── components
│ │ ├── Page.css
│ │ └── Page2.js
├── legacy-jsx-runtimes
│ ├── react-15
│ │ ├── package.json
│ │ ├── jsx-runtime.js
│ │ └── jsx-dev-runtime.js
│ ├── react-14
│ │ ├── package.json
│ │ ├── jsx-runtime.js
│ │ └── jsx-dev-runtime.js
│ ├── react-16
│ │ ├── package.json
│ │ ├── jsx-runtime.js
│ │ └── jsx-dev-runtime.js
│ ├── react-17
│ │ ├── package.json
│ │ ├── jsx-runtime.js
│ │ └── jsx-dev-runtime.js
│ ├── README.md
│ └── babel.config.js
├── attribute-behavior
│ ├── public
│ │ ├── favicon.ico
│ │ └── manifest.json
│ └── src
│ │ ├── index.css
│ │ ├── index.js
│ │ └── App.test.js
├── concurrent
│ └── time-slicing
│ │ ├── public
│ │ ├── favicon.ico
│ │ └── manifest.json
│ │ └── .gitignore
├── stacks
│ └── babel.config.json
├── ssr2
│ └── src
│ │ ├── Layout.js
│ │ ├── NavBar.js
│ │ └── index.js
├── fizz
│ └── src
│ │ └── index.js
└── expiration
│ └── .gitignore
├── scripts
├── release
│ ├── .gitignore
│ ├── ci-npmrc
│ ├── prepare-release-from-npm-commands
│ │ └── get-latest-next-version.js
│ └── build-release-locally-commands
│ │ └── update-version-numbers.js
├── devtools
│ ├── .gitignore
│ └── package.json
├── bench
│ ├── .gitignore
│ └── benchmarks
│ │ └── hacker-news
│ │ ├── logo.png
│ │ └── grayarrow.gif
├── perf-counters
│ ├── index.js
│ ├── Makefile
│ ├── package.json
│ ├── binding.gyp
│ └── README.md
├── eslint-rules
│ ├── package.json
│ └── README.md
├── jest
│ ├── dont-run-jest-directly.js
│ ├── setupTests.build.js
│ ├── setupTests.persistent.js
│ ├── setupGlobal.js
│ └── config.source.js
├── circleci
│ ├── test_print_warnings.sh
│ └── check_license.sh
├── rollup
│ ├── externs
│ │ └── closure-externs.js
│ ├── wrappers
│ │ ├── registerInternalModuleEnd.js
│ │ └── registerInternalModuleBegin.js
│ └── shims
│ │ ├── facebook-www
│ │ └── renderSubtreeIntoContainer_DO_NOT_USE.js
│ │ └── react-native
│ │ └── ReactFeatureFlags.js
├── print-warnings
│ └── README.md
├── git
│ └── pre-commit
├── authors
└── error-codes
│ └── Types.js
├── packages
├── internal-test-utils
│ ├── index.js
│ └── package.json
├── react-server-dom-esm
│ ├── esm
│ │ ├── package.json
│ │ └── react-server-dom-esm-node-loader.production.min.js
│ ├── npm
│ │ ├── esm
│ │ │ └── package.json
│ │ ├── client.js
│ │ ├── server.js
│ │ ├── client.node.js
│ │ ├── server.node.js
│ │ ├── client.browser.js
│ │ └── index.js
│ ├── README.md
│ ├── client.js
│ ├── client.node.js
│ ├── server.node.js
│ ├── client.browser.js
│ ├── index.js
│ └── server.js
├── react-devtools-core
│ ├── backend.js
│ └── standalone.js
├── react-server-dom-turbopack
│ ├── esm
│ │ ├── package.json
│ │ └── react-server-dom-turbopack-node-loader.production.min.js
│ ├── npm
│ │ ├── esm
│ │ │ └── package.json
│ │ ├── client.js
│ │ ├── node-register.js
│ │ ├── server.js
│ │ ├── client.edge.js
│ │ ├── client.node.js
│ │ ├── server.edge.js
│ │ ├── server.node.js
│ │ ├── client.browser.js
│ │ ├── server.browser.js
│ │ ├── client.node.unbundled.js
│ │ ├── server.node.unbundled.js
│ │ └── index.js
│ ├── README.md
│ ├── client.js
│ ├── client.edge.js
│ ├── client.node.js
│ ├── server.edge.js
│ ├── server.node.js
│ ├── client.browser.js
│ ├── client.node.unbundled.js
│ ├── server.browser.js
│ ├── server.node.unbundled.js
│ ├── index.js
│ ├── node-register.js
│ ├── src
│ │ ├── ReactFlightClientConfigBundlerTurbopackBrowser.js
│ │ └── ReactFlightClientConfigBundlerTurbopackServer.js
│ └── server.js
├── react-server-dom-webpack
│ ├── esm
│ │ ├── package.json
│ │ └── react-server-dom-webpack-node-loader.production.min.js
│ ├── npm
│ │ ├── esm
│ │ │ └── package.json
│ │ ├── client.js
│ │ ├── plugin.js
│ │ ├── node-register.js
│ │ ├── server.js
│ │ ├── client.edge.js
│ │ ├── client.node.js
│ │ ├── server.edge.js
│ │ ├── server.node.js
│ │ ├── client.browser.js
│ │ ├── server.browser.js
│ │ ├── client.node.unbundled.js
│ │ ├── server.node.unbundled.js
│ │ └── index.js
│ ├── README.md
│ ├── client.js
│ ├── client.edge.js
│ ├── client.node.js
│ ├── server.edge.js
│ ├── server.node.js
│ ├── client.browser.js
│ ├── plugin.js
│ ├── server.browser.js
│ ├── client.node.unbundled.js
│ ├── index.js
│ ├── server.node.unbundled.js
│ ├── node-register.js
│ ├── src
│ │ └── ReactFlightClientConfigBundlerWebpackServer.js
│ └── server.js
├── react-devtools-inline
│ ├── backend.js
│ ├── frontend.js
│ ├── hookNames.js
│ └── src
│ │ └── hookNames.js
├── react-devtools-shared
│ ├── src
│ │ ├── __tests__
│ │ │ └── __mocks__
│ │ │ │ └── cssMock.js
│ │ ├── devtools
│ │ │ ├── views
│ │ │ │ ├── Profiler
│ │ │ │ │ ├── RootSelector.css
│ │ │ │ │ ├── CommitRanked.css
│ │ │ │ │ ├── CommitFlamegraph.css
│ │ │ │ │ ├── constants.js
│ │ │ │ │ └── NoCommitData.css
│ │ │ │ ├── Components
│ │ │ │ │ ├── InspectedElementErrorBoundary.css
│ │ │ │ │ ├── ForgetBadge.css
│ │ │ │ │ ├── LoadingAnimation.css
│ │ │ │ │ ├── InspectedElementStyleXPlugin.css
│ │ │ │ │ ├── constants.js
│ │ │ │ │ ├── ExpandCollapseToggle.css
│ │ │ │ │ ├── InspectedElementBadges.css
│ │ │ │ │ ├── EditableName.css
│ │ │ │ │ ├── NewKeyValue.css
│ │ │ │ │ ├── ElementBadges.css
│ │ │ │ │ ├── IndexableElementBadges.css
│ │ │ │ │ ├── SelectedTreeHighlight.css
│ │ │ │ │ ├── Badge.css
│ │ │ │ │ ├── NativeStyleEditor
│ │ │ │ │ │ └── AutoSizeInput.css
│ │ │ │ │ └── NewArrayValue.css
│ │ │ │ ├── Icon.css
│ │ │ │ ├── ButtonIcon.css
│ │ │ │ ├── ReactLogo.css
│ │ │ │ ├── WarnIfLegacyBackendDetected.css
│ │ │ │ ├── UnsupportedVersionDialog.css
│ │ │ │ ├── ErrorBoundary
│ │ │ │ │ └── index.js
│ │ │ │ └── root.css
│ │ │ └── ContextMenu
│ │ │ │ └── ContextMenu.css
│ │ ├── node_modules
│ │ │ └── react-window
│ │ │ │ └── dist
│ │ │ │ ├── index.cjs.js.flow
│ │ │ │ └── index.esm.js.flow
│ │ ├── hooks
│ │ │ └── __tests__
│ │ │ │ └── __source__
│ │ │ │ ├── __untransformed__
│ │ │ │ └── README.md
│ │ │ │ ├── InlineRequire.js
│ │ │ │ └── README.md
│ │ └── isArray.js
│ └── README.md
├── react-dom
│ ├── npm
│ │ ├── server.js
│ │ ├── static.js
│ │ ├── test-utils.js
│ │ ├── react-dom.shared-subset.js
│ │ ├── server-rendering-stub.js
│ │ ├── static.edge.js
│ │ ├── static.browser.js
│ │ └── static.node.js
│ ├── server.js
│ ├── static.js
│ ├── test-utils.js
│ ├── unstable_testing.stable.js
│ ├── src
│ │ └── server
│ │ │ ├── react-dom-server.bun.js
│ │ │ ├── react-dom-server.edge.stable.js
│ │ │ ├── react-dom-server.node.stable.js
│ │ │ ├── react-dom-server.browser.stable.js
│ │ │ ├── react-dom-server.edge.js
│ │ │ ├── react-dom-server.browser.js
│ │ │ ├── react-dom-server.node.js
│ │ │ └── react-dom-server.bun.stable.js
│ ├── static.edge.js
│ ├── static.browser.js
│ ├── unstable_server-external-runtime.js
│ └── static.node.js
├── jest-react
│ ├── README.md
│ ├── npm
│ │ └── index.js
│ └── index.js
├── shared
│ ├── package.json
│ ├── assign.js
│ ├── getPrototypeOf.js
│ ├── hasOwnProperty.js
│ ├── ReactSharedInternals.js
│ ├── ExecutionEnvironment.js
│ └── ReactDOMSharedInternals.js
├── react-test-renderer
│ ├── npm
│ │ ├── shallow.js
│ │ └── index.js
│ ├── index.js
│ └── shallow.js
├── react-devtools
│ └── icons
│ │ └── icon128.png
├── react-suspense-test-utils
│ ├── npm
│ │ └── index.js
│ ├── index.js
│ └── README.md
├── dom-event-testing-library
│ └── package.json
├── react-devtools-timeline
│ ├── src
│ │ ├── CanvasPage.css
│ │ ├── view-base
│ │ │ ├── resizable
│ │ │ │ └── index.js
│ │ │ └── vertical-scroll-overflow
│ │ │ │ └── index.js
│ │ ├── import-worker
│ │ │ ├── importFile.worker.js
│ │ │ └── InvalidProfileError.js
│ │ └── utils
│ │ │ └── flow.js
│ └── README.md
├── react-devtools-extensions
│ ├── icons
│ │ ├── 128-deadcode.png
│ │ ├── 128-disabled.png
│ │ ├── 128-outdated.png
│ │ ├── 16-deadcode.png
│ │ ├── 16-disabled.png
│ │ ├── 16-outdated.png
│ │ ├── 16-production.png
│ │ ├── 16-restricted.png
│ │ ├── 16-unminified.png
│ │ ├── 32-deadcode.png
│ │ ├── 32-disabled.png
│ │ ├── 32-outdated.png
│ │ ├── 32-production.png
│ │ ├── 32-restricted.png
│ │ ├── 32-unminified.png
│ │ ├── 48-deadcode.png
│ │ ├── 48-disabled.png
│ │ ├── 48-outdated.png
│ │ ├── 48-production.png
│ │ ├── 48-restricted.png
│ │ ├── 48-unminified.png
│ │ ├── 128-development.png
│ │ ├── 128-production.png
│ │ ├── 128-restricted.png
│ │ ├── 128-unminified.png
│ │ ├── 16-development.png
│ │ ├── 32-development.png
│ │ └── 48-development.png
│ ├── edge
│ │ ├── now.json
│ │ └── deploy.js
│ ├── chrome
│ │ ├── now.json
│ │ └── deploy.js
│ ├── firefox
│ │ ├── now.json
│ │ └── deploy.js
│ ├── main.html
│ ├── src
│ │ └── main
│ │ │ ├── debounce.js
│ │ │ └── injectBackendManager.js
│ ├── deploy.edge.html
│ ├── deploy.chrome.html
│ ├── deploy.firefox.html
│ └── popups
│ │ ├── restricted.html
│ │ └── shared.css
├── react-interactions
│ ├── README.md
│ ├── npm
│ │ ├── drag.js
│ │ ├── tap.js
│ │ ├── focus.js
│ │ ├── hover.js
│ │ ├── input.js
│ │ ├── press.js
│ │ ├── scroll.js
│ │ ├── swipe.js
│ │ └── press-legacy.js
│ └── events
│ │ └── focus.js
├── react-devtools-shell
│ ├── constants.js
│ └── src
│ │ └── app
│ │ ├── InspectableElements
│ │ ├── UseMemoCache.js
│ │ └── index.js
│ │ ├── ToDoList
│ │ ├── List.css
│ │ ├── index.js
│ │ └── ListItem.css
│ │ └── styles.css
├── react-noop-renderer
│ ├── README.md
│ ├── npm
│ │ ├── index.js
│ │ ├── server.js
│ │ ├── persistent.js
│ │ ├── flight-client.js
│ │ └── flight-server.js
│ ├── index.js
│ ├── server.js
│ ├── persistent.js
│ ├── flight-client.js
│ └── flight-server.js
├── react-reconciler
│ ├── src
│ │ ├── __tests__
│ │ │ └── __snapshots__
│ │ │ │ └── ReactHooks-test.internal.js.snap
│ │ ├── forks
│ │ │ ├── ReactFiberConfig.art.js
│ │ │ ├── ReactFiberConfig.dom.js
│ │ │ ├── ReactFiberConfig.fabric.js
│ │ │ ├── ReactFiberConfig.native.js
│ │ │ └── ReactFiberConfig.test.js
│ │ ├── ReactRootTags.js
│ │ └── __mocks__
│ │ │ └── scheduler
│ │ │ └── tracing.js
│ ├── npm
│ │ ├── index.js
│ │ ├── constants.js
│ │ └── reflection.js
│ ├── index.js
│ ├── constants.js
│ └── reflection.js
├── react
│ ├── npm
│ │ ├── index.js
│ │ ├── jsx-runtime.js
│ │ ├── jsx-dev-runtime.js
│ │ ├── react.shared-subset.js
│ │ └── unstable-cache.js
│ ├── jsx-runtime.js
│ ├── react.shared-subset.js
│ ├── jsx-dev-runtime.js
│ └── src
│ │ ├── ReactSharedSubsetFB.js
│ │ └── ReactServerContextRegistry.js
├── react-art
│ ├── npm
│ │ └── index.js
│ ├── index.js
│ ├── Circle.js
│ ├── Wedge.js
│ ├── Rectangle.js
│ └── README.md
├── react-is
│ ├── npm
│ │ └── index.js
│ └── index.js
├── scheduler
│ ├── npm
│ │ ├── index.js
│ │ ├── index.native.js
│ │ ├── unstable_mock.js
│ │ └── unstable_post_task.js
│ ├── index.js
│ ├── unstable_mock.js
│ ├── unstable_post_task.js
│ ├── index.native.js
│ └── README.md
├── react-cache
│ ├── npm
│ │ └── index.js
│ └── index.js
├── react-server
│ ├── npm
│ │ ├── index.js
│ │ └── flight.js
│ ├── README.md
│ ├── flight.js
│ ├── index.js
│ └── src
│ │ └── forks
│ │ ├── ReactServerStreamConfig.dom-bun.js
│ │ ├── ReactServerStreamConfig.dom-edge.js
│ │ ├── ReactServerStreamConfig.dom-node.js
│ │ ├── ReactServerStreamConfig.dom-browser.js
│ │ └── ReactServerStreamConfig.dom-legacy.js
├── use-subscription
│ ├── npm
│ │ └── index.js
│ └── index.js
├── react-client
│ ├── npm
│ │ └── flight.js
│ ├── README.md
│ └── flight.js
├── react-debug-tools
│ ├── npm
│ │ └── index.js
│ ├── index.js
│ ├── README.md
│ └── src
│ │ └── ReactDebugTools.js
├── react-refresh
│ ├── npm
│ │ ├── babel.js
│ │ └── runtime.js
│ ├── runtime.js
│ └── babel.js
├── eslint-plugin-react-hooks
│ ├── index.js
│ └── npm
│ │ └── index.js
├── use-sync-external-store
│ ├── npm
│ │ ├── index.js
│ │ ├── shim
│ │ │ ├── index.js
│ │ │ ├── index.native.js
│ │ │ └── with-selector.js
│ │ └── with-selector.js
│ ├── README.md
│ ├── src
│ │ ├── forks
│ │ │ └── isServerEnvironment.native.js
│ │ └── isServerEnvironment.js
│ ├── index.js
│ ├── shim
│ │ ├── index.js
│ │ ├── index.native.js
│ │ └── with-selector
│ │ │ └── index.js
│ └── with-selector.js
├── react-dom-bindings
│ └── src
│ │ ├── server
│ │ └── fizz-instruction-set
│ │ │ ├── ReactDOMFizzInlineCompleteSegment.js
│ │ │ ├── ReactDOMFizzInlineCompleteBoundary.js
│ │ │ ├── ReactDOMFizzInlineClientRenderBoundary.js
│ │ │ └── ReactDOMFizzInlineCompleteBoundaryWithStyles.js
│ │ ├── client
│ │ └── DOMNamespaces.js
│ │ └── events
│ │ └── PluginModuleType.js
├── react-native-renderer
│ ├── src
│ │ ├── __mocks__
│ │ │ └── react-native
│ │ │ │ └── Libraries
│ │ │ │ └── ReactPrivate
│ │ │ │ ├── Platform.js
│ │ │ │ ├── legacySendAccessibilityEvent.js
│ │ │ │ ├── ExceptionsManager.js
│ │ │ │ ├── ReactFiberErrorDialog.js
│ │ │ │ ├── RCTEventEmitter.js
│ │ │ │ ├── BatchedBridge.js
│ │ │ │ ├── flattenStyle.js
│ │ │ │ └── ReactNativePrivateInitializeCore.js
│ │ ├── __tests__
│ │ │ └── __snapshots__
│ │ │ │ └── ReactNativeEvents-test.internal.js.snap
│ │ └── ReactNativeEventPluginOrder.js
│ └── package.json
└── react-server-dom-fb
│ └── package.json
├── CONTRIBUTING.md
├── netlify.toml
├── .editorconfig
├── SECURITY.md
├── .codesandbox
└── ci.json
├── .github
└── ISSUE_TEMPLATE
│ └── config.yml
└── .prettierrc.js
/.nvmrc:
--------------------------------------------------------------------------------
1 | v16.19.1
2 |
--------------------------------------------------------------------------------
/.watchmanconfig:
--------------------------------------------------------------------------------
1 | {}
2 |
--------------------------------------------------------------------------------
/.gitattributes:
--------------------------------------------------------------------------------
1 | * text=auto
2 |
--------------------------------------------------------------------------------
/fixtures/art/.gitignore:
--------------------------------------------------------------------------------
1 | bundle.js
--------------------------------------------------------------------------------
/fixtures/flight/.nvmrc:
--------------------------------------------------------------------------------
1 | v18
2 |
--------------------------------------------------------------------------------
/fixtures/flight-esm/.nvmrc:
--------------------------------------------------------------------------------
1 | v18
2 |
--------------------------------------------------------------------------------
/fixtures/packaging/rjs/dev/.gitignore:
--------------------------------------------------------------------------------
1 | output.js
--------------------------------------------------------------------------------
/fixtures/packaging/rjs/prod/.gitignore:
--------------------------------------------------------------------------------
1 | output.js
--------------------------------------------------------------------------------
/scripts/release/.gitignore:
--------------------------------------------------------------------------------
1 | .progress-estimator
--------------------------------------------------------------------------------
/fixtures/nesting/.eslintignore:
--------------------------------------------------------------------------------
1 | src/*/node_modules
2 |
--------------------------------------------------------------------------------
/fixtures/packaging/webpack/dev/.gitignore:
--------------------------------------------------------------------------------
1 | output.js
--------------------------------------------------------------------------------
/fixtures/packaging/webpack/prod/.gitignore:
--------------------------------------------------------------------------------
1 | output.js
--------------------------------------------------------------------------------
/fixtures/fiber-debugger/.env:
--------------------------------------------------------------------------------
1 | NODE_PATH=../../build/packages
--------------------------------------------------------------------------------
/fixtures/nesting/src/index.js:
--------------------------------------------------------------------------------
1 | import './modern/index';
2 |
--------------------------------------------------------------------------------
/fixtures/packaging/browserify/dev/.gitignore:
--------------------------------------------------------------------------------
1 | output.js
2 |
--------------------------------------------------------------------------------
/fixtures/packaging/webpack-alias/dev/.gitignore:
--------------------------------------------------------------------------------
1 | output.js
--------------------------------------------------------------------------------
/fixtures/packaging/webpack-alias/prod/.gitignore:
--------------------------------------------------------------------------------
1 | output.js
--------------------------------------------------------------------------------
/fixtures/packaging/browserify/prod/.gitignore:
--------------------------------------------------------------------------------
1 | output.js
2 |
--------------------------------------------------------------------------------
/fixtures/packaging/systemjs-builder/dev/.gitignore:
--------------------------------------------------------------------------------
1 | output.js
--------------------------------------------------------------------------------
/fixtures/packaging/systemjs-builder/prod/.gitignore:
--------------------------------------------------------------------------------
1 | output.js
--------------------------------------------------------------------------------
/fixtures/devtools/scheduling-profiler/.gitignore:
--------------------------------------------------------------------------------
1 | dependencies
2 |
--------------------------------------------------------------------------------
/fixtures/flight/src/cjs/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "type":"commonjs"
3 | }
--------------------------------------------------------------------------------
/fixtures/packaging/brunch/dev/.gitignore:
--------------------------------------------------------------------------------
1 | output.js
2 | output.js.map
--------------------------------------------------------------------------------
/fixtures/packaging/brunch/prod/.gitignore:
--------------------------------------------------------------------------------
1 | output.js
2 | output.js.map
--------------------------------------------------------------------------------
/fixtures/flight/config/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "commonjs"
3 | }
4 |
--------------------------------------------------------------------------------
/fixtures/flight/loader/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "module"
3 | }
4 |
--------------------------------------------------------------------------------
/fixtures/flight/scripts/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "commonjs"
3 | }
4 |
--------------------------------------------------------------------------------
/fixtures/flight/server/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "commonjs"
3 | }
4 |
--------------------------------------------------------------------------------
/fixtures/flight/src/style.css:
--------------------------------------------------------------------------------
1 | body {
2 | font-family: Helvetica;
3 | }
--------------------------------------------------------------------------------
/scripts/devtools/.gitignore:
--------------------------------------------------------------------------------
1 | .build-metadata
2 | .progress-estimator
3 |
--------------------------------------------------------------------------------
/fixtures/flight-esm/loader/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "module"
3 | }
4 |
--------------------------------------------------------------------------------
/fixtures/flight-esm/server/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "commonjs"
3 | }
4 |
--------------------------------------------------------------------------------
/fixtures/flight-esm/src/style.css:
--------------------------------------------------------------------------------
1 | body {
2 | font-family: Helvetica;
3 | }
--------------------------------------------------------------------------------
/fixtures/nesting/.env:
--------------------------------------------------------------------------------
1 | EXTEND_ESLINT=true
2 | SKIP_PREFLIGHT_CHECK=true
3 |
--------------------------------------------------------------------------------
/scripts/release/ci-npmrc:
--------------------------------------------------------------------------------
1 | //registry.npmjs.org/:_authToken=${NPM_TOKEN}
2 |
--------------------------------------------------------------------------------
/packages/internal-test-utils/index.js:
--------------------------------------------------------------------------------
1 | export * from './ReactInternalTestUtils';
2 |
--------------------------------------------------------------------------------
/packages/react-server-dom-esm/esm/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "module"
3 | }
4 |
--------------------------------------------------------------------------------
/fixtures/flight/src/Counter2.js:
--------------------------------------------------------------------------------
1 | 'use client';
2 |
3 | export * from './Counter.js';
4 |
--------------------------------------------------------------------------------
/packages/react-devtools-core/backend.js:
--------------------------------------------------------------------------------
1 | module.exports = require('./dist/backend');
2 |
--------------------------------------------------------------------------------
/packages/react-server-dom-esm/npm/esm/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "module"
3 | }
4 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/esm/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "module"
3 | }
4 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/esm/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "module"
3 | }
4 |
--------------------------------------------------------------------------------
/scripts/bench/.gitignore:
--------------------------------------------------------------------------------
1 | react-dom.production.min.js
2 | react.production.min.js
3 |
--------------------------------------------------------------------------------
/fixtures/eslint/proxy/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "private": true,
3 | "version": "0.0.0"
4 | }
--------------------------------------------------------------------------------
/packages/react-devtools-core/standalone.js:
--------------------------------------------------------------------------------
1 | module.exports = require('./dist/standalone');
2 |
--------------------------------------------------------------------------------
/packages/react-devtools-inline/backend.js:
--------------------------------------------------------------------------------
1 | module.exports = require('./dist/backend');
2 |
--------------------------------------------------------------------------------
/packages/react-devtools-inline/frontend.js:
--------------------------------------------------------------------------------
1 | module.exports = require('./dist/frontend');
2 |
--------------------------------------------------------------------------------
/packages/react-devtools-inline/hookNames.js:
--------------------------------------------------------------------------------
1 | module.exports = require('./dist/hookNames');
2 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/__tests__/__mocks__/cssMock.js:
--------------------------------------------------------------------------------
1 | module.exports = {};
2 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/npm/esm/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "module"
3 | }
4 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/npm/esm/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "type": "module"
3 | }
4 |
--------------------------------------------------------------------------------
/packages/react-dom/npm/server.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | module.exports = require('./server.node');
4 |
--------------------------------------------------------------------------------
/packages/react-dom/npm/static.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | module.exports = require('./static.node');
4 |
--------------------------------------------------------------------------------
/fixtures/dom/public/test.mp4:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/fixtures/dom/public/test.mp4
--------------------------------------------------------------------------------
/packages/jest-react/README.md:
--------------------------------------------------------------------------------
1 | # `jest-react`
2 |
3 | Jest matchers and utilities for testing React Test Renderer.
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/Profiler/RootSelector.css:
--------------------------------------------------------------------------------
1 | .Spacer {
2 | flex: 1;
3 | }
4 |
--------------------------------------------------------------------------------
/packages/shared/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "private": true,
3 | "name": "shared",
4 | "version": "0.0.0"
5 | }
6 |
--------------------------------------------------------------------------------
/scripts/perf-counters/index.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | module.exports = require('bindings')('perfcounters');
4 |
--------------------------------------------------------------------------------
/fixtures/dom/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/fixtures/dom/public/favicon.ico
--------------------------------------------------------------------------------
/fixtures/ssr/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/fixtures/ssr/public/favicon.ico
--------------------------------------------------------------------------------
/packages/react-server-dom-esm/npm/client.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | module.exports = require('./client.browser');
4 |
--------------------------------------------------------------------------------
/scripts/eslint-rules/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "eslint-plugin-react-internal",
3 | "version": "0.0.0"
4 | }
5 |
--------------------------------------------------------------------------------
/fixtures/flight/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/fixtures/flight/public/favicon.ico
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/npm/client.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | module.exports = require('./client.browser');
4 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/npm/client.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | module.exports = require('./client.browser');
4 |
--------------------------------------------------------------------------------
/packages/react-test-renderer/npm/shallow.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | module.exports = require('react-shallow-renderer');
4 |
--------------------------------------------------------------------------------
/fixtures/flight-esm/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/fixtures/flight-esm/public/favicon.ico
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/Components/InspectedElementErrorBoundary.css:
--------------------------------------------------------------------------------
1 | .Wrapper {
2 | height: 100%;
3 | }
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/node_modules/react-window/dist/index.cjs.js.flow:
--------------------------------------------------------------------------------
1 | // @flow
2 |
3 | export * from '../src';
4 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/node_modules/react-window/dist/index.esm.js.flow:
--------------------------------------------------------------------------------
1 | // @flow
2 |
3 | export * from '../src';
4 |
--------------------------------------------------------------------------------
/fixtures/fiber-debugger/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/fixtures/fiber-debugger/public/favicon.ico
--------------------------------------------------------------------------------
/packages/internal-test-utils/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "private": true,
3 | "name": "internal-test-utils",
4 | "version": "0.0.0"
5 | }
6 |
--------------------------------------------------------------------------------
/packages/react-devtools/icons/icon128.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools/icons/icon128.png
--------------------------------------------------------------------------------
/packages/react-suspense-test-utils/npm/index.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | module.exports = require('./cjs/react-suspense-test-utils.js');
4 |
--------------------------------------------------------------------------------
/scripts/jest/dont-run-jest-directly.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | throw new Error("Don't run `jest` directly. Run `yarn test` instead.");
4 |
--------------------------------------------------------------------------------
/fixtures/legacy-jsx-runtimes/react-15/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "dependencies": {
3 | "react": "15",
4 | "react-dom": "15"
5 | }
6 | }
7 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/Icon.css:
--------------------------------------------------------------------------------
1 | .Icon {
2 | width: 1rem;
3 | height: 1rem;
4 | fill: currentColor;
5 | }
6 |
--------------------------------------------------------------------------------
/scripts/bench/benchmarks/hacker-news/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/scripts/bench/benchmarks/hacker-news/logo.png
--------------------------------------------------------------------------------
/fixtures/attribute-behavior/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/fixtures/attribute-behavior/public/favicon.ico
--------------------------------------------------------------------------------
/fixtures/legacy-jsx-runtimes/react-14/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "dependencies": {
3 | "react": "0.14",
4 | "react-dom": "0.14"
5 | }
6 | }
7 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/Components/ForgetBadge.css:
--------------------------------------------------------------------------------
1 | .Root {
2 | background-color: var(--color-forget-badge);
3 | }
4 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/npm/plugin.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | module.exports = require('./cjs/react-server-dom-webpack-plugin.js');
4 |
--------------------------------------------------------------------------------
/packages/dom-event-testing-library/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "private": true,
3 | "name": "dom-event-testing-library",
4 | "version": "0.0.0"
5 | }
6 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/ButtonIcon.css:
--------------------------------------------------------------------------------
1 | .ButtonIcon {
2 | width: 1rem;
3 | height: 1rem;
4 | fill: currentColor;
5 | }
6 |
--------------------------------------------------------------------------------
/scripts/bench/benchmarks/hacker-news/grayarrow.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/scripts/bench/benchmarks/hacker-news/grayarrow.gif
--------------------------------------------------------------------------------
/fixtures/concurrent/time-slicing/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/fixtures/concurrent/time-slicing/public/favicon.ico
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/Profiler/CommitRanked.css:
--------------------------------------------------------------------------------
1 | .Container {
2 | width: 100%;
3 | flex: 1;
4 | padding: 0.5rem;
5 | }
6 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/npm/node-register.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | module.exports = require('./cjs/react-server-dom-webpack-node-register.js');
4 |
--------------------------------------------------------------------------------
/fixtures/attribute-behavior/src/index.css:
--------------------------------------------------------------------------------
1 | * {
2 | box-sizing: border-box;
3 | }
4 |
5 | body {
6 | font-family: monospace;
7 | font-size: 12px;
8 | }
9 |
--------------------------------------------------------------------------------
/fixtures/packaging/webpack/dev/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/packages/react-devtools-timeline/src/CanvasPage.css:
--------------------------------------------------------------------------------
1 | .CanvasPage {
2 | position: absolute;
3 | top: 0;
4 | bottom: 0;
5 | left: 0;
6 | right: 0;
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/npm/node-register.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | module.exports = require('./cjs/react-server-dom-turbopack-node-register.js');
4 |
--------------------------------------------------------------------------------
/fixtures/flight/src/Container.js:
--------------------------------------------------------------------------------
1 | import * as React from 'react';
2 |
3 | export default function Container({children}) {
4 | return {children}
;
5 | }
6 |
--------------------------------------------------------------------------------
/fixtures/packaging/browserify/dev/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/fixtures/packaging/browserify/prod/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/fixtures/packaging/webpack/prod/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/128-deadcode.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/128-deadcode.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/128-disabled.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/128-disabled.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/128-outdated.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/128-outdated.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/16-deadcode.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/16-deadcode.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/16-disabled.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/16-disabled.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/16-outdated.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/16-outdated.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/16-production.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/16-production.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/16-restricted.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/16-restricted.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/16-unminified.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/16-unminified.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/32-deadcode.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/32-deadcode.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/32-disabled.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/32-disabled.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/32-outdated.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/32-outdated.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/32-production.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/32-production.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/32-restricted.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/32-restricted.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/32-unminified.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/32-unminified.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/48-deadcode.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/48-deadcode.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/48-disabled.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/48-disabled.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/48-outdated.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/48-outdated.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/48-production.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/48-production.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/48-restricted.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/48-restricted.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/48-unminified.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/48-unminified.png
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/Components/LoadingAnimation.css:
--------------------------------------------------------------------------------
1 | .Icon {
2 | width: 1rem;
3 | height: 1rem;
4 | fill: currentColor;
5 | }
6 |
--------------------------------------------------------------------------------
/packages/react-server-dom-esm/README.md:
--------------------------------------------------------------------------------
1 | # react-server-dom-esm
2 |
3 | Experimental React Flight bindings for DOM using ESM.
4 |
5 | **Use it at your own risk.**
6 |
--------------------------------------------------------------------------------
/fixtures/flight/src/cjs/Counter3.js:
--------------------------------------------------------------------------------
1 | "use client";
2 | // CJS-ESM async module
3 | module.exports = import('../Counter.js').then(m => {
4 | return m.Counter
5 | });
6 |
--------------------------------------------------------------------------------
/fixtures/nesting/src/shared/ThemeContext.js:
--------------------------------------------------------------------------------
1 | import {createContext} from 'react';
2 |
3 | const ThemeContext = createContext(null);
4 |
5 | export default ThemeContext;
6 |
--------------------------------------------------------------------------------
/fixtures/packaging/systemjs-builder/dev/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/fixtures/packaging/systemjs-builder/prod/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/fixtures/packaging/webpack-alias/dev/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/fixtures/packaging/webpack-alias/prod/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/128-development.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/128-development.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/128-production.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/128-production.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/128-restricted.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/128-restricted.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/128-unminified.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/128-unminified.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/16-development.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/16-development.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/32-development.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/32-development.png
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/icons/48-development.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tanveerpot/react/HEAD/packages/react-devtools-extensions/icons/48-development.png
--------------------------------------------------------------------------------
/fixtures/legacy-jsx-runtimes/react-16/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "dependencies": {
3 | "prop-types": "^15.7.2",
4 | "react": "16",
5 | "react-dom": "16"
6 | }
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-interactions/README.md:
--------------------------------------------------------------------------------
1 | # `react-interactions`
2 |
3 | This package is experimental. It is intended for use with the experimental React
4 | flags for internal testing.
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/README.md:
--------------------------------------------------------------------------------
1 | # react-server-dom-webpack
2 |
3 | Experimental React Flight bindings for DOM using Webpack.
4 |
5 | **Use it at your own risk.**
6 |
--------------------------------------------------------------------------------
/packages/react-devtools-shell/constants.js:
--------------------------------------------------------------------------------
1 | const SUCCESSFUL_COMPILATION_MESSAGE = 'Compiled successfully.';
2 |
3 | module.exports = {
4 | SUCCESSFUL_COMPILATION_MESSAGE,
5 | };
6 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/README.md:
--------------------------------------------------------------------------------
1 | # react-server-dom-turbopack
2 |
3 | Experimental React Flight bindings for DOM using Turbopack.
4 |
5 | **Use it at your own risk.**
6 |
--------------------------------------------------------------------------------
/scripts/circleci/test_print_warnings.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -e
4 |
5 | WARNINGS=$(node scripts/print-warnings/print-warnings.js)
6 | echo "$WARNINGS"
7 | test ! -z "$WARNINGS"
8 |
--------------------------------------------------------------------------------
/scripts/rollup/externs/closure-externs.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @externs
3 | */
4 | /* eslint-disable */
5 |
6 | 'use strict';
7 |
8 | /** @type {function} */
9 | var addEventListener;
10 |
--------------------------------------------------------------------------------
/fixtures/legacy-jsx-runtimes/react-17/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "dependencies": {
3 | "prop-types": "^15.7.2",
4 | "react": "17.0.0-rc.3",
5 | "react-dom": "17.0.0-rc.3"
6 | }
7 | }
8 |
--------------------------------------------------------------------------------
/scripts/jest/setupTests.build.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | jest.mock('scheduler', () => jest.requireActual('scheduler/unstable_mock'));
4 |
5 | global.__unmockReact = () => jest.unmock('react');
6 |
--------------------------------------------------------------------------------
/fixtures/art/README.md:
--------------------------------------------------------------------------------
1 | # VectorWidget example
2 |
3 | To try this example, run:
4 |
5 | ```
6 | yarn
7 | yarn build
8 | ```
9 |
10 | in this directory, then open index.html in your browser.
11 |
--------------------------------------------------------------------------------
/fixtures/stacks/babel.config.json:
--------------------------------------------------------------------------------
1 | {
2 | "plugins": [
3 | ["@babel/plugin-proposal-class-properties", {"loose": false}],
4 | ["@babel/plugin-transform-classes", {"loose": true}]
5 | ]
6 | }
7 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/ReactLogo.css:
--------------------------------------------------------------------------------
1 | .ReactLogo {
2 | width: 1.75rem;
3 | height: 1.75rem;
4 | margin: 0 0.75rem 0 0.25rem;
5 | color: var(--color-button-active);
6 | }
7 |
--------------------------------------------------------------------------------
/scripts/jest/setupTests.persistent.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | jest.mock('react-noop-renderer', () =>
4 | jest.requireActual('react-noop-renderer/persistent')
5 | );
6 |
7 | global.__PERSISTENT__ = true;
8 |
--------------------------------------------------------------------------------
/fixtures/eslint/watch.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 | (cd ../.. && yarn build eslint --type=NODE_DEV)
3 | (cd ../.. && watchman-make --make 'yarn build eslint --type=NODE_DEV' -p 'packages/eslint-plugin-*/**/*' -t ignored)
4 |
--------------------------------------------------------------------------------
/fixtures/packaging/brunch/dev/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/fixtures/packaging/brunch/prod/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/fixtures/packaging/brunch/dev/config.js:
--------------------------------------------------------------------------------
1 | exports.config = {
2 | paths: {
3 | public: '.',
4 | },
5 | files: {
6 | javascripts: {
7 | joinTo: 'output.js',
8 | },
9 | },
10 | };
11 |
--------------------------------------------------------------------------------
/fixtures/packaging/brunch/prod/config.js:
--------------------------------------------------------------------------------
1 | exports.config = {
2 | paths: {
3 | public: '.',
4 | },
5 | files: {
6 | javascripts: {
7 | joinTo: 'output.js',
8 | },
9 | },
10 | };
11 |
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/edge/now.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "react-devtools-experimental-edge",
3 | "alias": ["react-devtools-experimental-edge"],
4 | "files": ["index.html", "ReactDevTools.zip"]
5 | }
6 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/Components/InspectedElementStyleXPlugin.css:
--------------------------------------------------------------------------------
1 | .Source {
2 | color: var(--color-dim);
3 | margin-left: 1rem;
4 | overflow: auto;
5 | text-overflow: ellipsis;
6 | }
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/Components/constants.js:
--------------------------------------------------------------------------------
1 | export const PROTOCOLS_SUPPORTED_AS_LINKS_IN_KEY_VALUE = [
2 | 'file:///',
3 | 'http://',
4 | 'https://',
5 | 'vscode://',
6 | ];
7 |
--------------------------------------------------------------------------------
/fixtures/nesting/src/shared/Clock.js:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 |
3 | import useTime from './useTime';
4 |
5 | export default function Clock() {
6 | const time = useTime();
7 | return Time: {time}
;
8 | }
9 |
--------------------------------------------------------------------------------
/fixtures/ssr/src/index.js:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import {hydrateRoot} from 'react-dom/client';
3 |
4 | import App from './components/App';
5 |
6 | hydrateRoot(document, );
7 |
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/chrome/now.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "react-devtools-experimental-chrome",
3 | "alias": ["react-devtools-experimental-chrome"],
4 | "files": ["index.html", "ReactDevTools.zip"]
5 | }
6 |
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/firefox/now.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "react-devtools-experimental-firefox",
3 | "alias": ["react-devtools-experimental-firefox"],
4 | "files": ["index.html", "ReactDevTools.zip"]
5 | }
6 |
--------------------------------------------------------------------------------
/fixtures/fiber-debugger/src/index.js:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import ReactDOM from 'react-dom';
3 | import App from './App';
4 | import './index.css';
5 |
6 | ReactDOM.render(, document.getElementById('root'));
7 |
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/edge/deploy.js:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env node
2 |
3 | 'use strict';
4 |
5 | const deploy = require('../deploy');
6 |
7 | const main = async () => await deploy('edge');
8 |
9 | main();
10 |
--------------------------------------------------------------------------------
/packages/react-noop-renderer/README.md:
--------------------------------------------------------------------------------
1 | # `react-noop-renderer`
2 |
3 | This package is the renderer we use for debugging [Fiber](https://github.com/facebook/react/issues/6170).
4 | It is not intended to be used directly.
5 |
--------------------------------------------------------------------------------
/fixtures/attribute-behavior/src/index.js:
--------------------------------------------------------------------------------
1 | import './index.css';
2 | import React from 'react';
3 | import ReactDOM from 'react-dom';
4 | import App from './App';
5 |
6 | ReactDOM.render(, document.getElementById('root'));
7 |
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/chrome/deploy.js:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env node
2 |
3 | 'use strict';
4 |
5 | const deploy = require('../deploy');
6 |
7 | const main = async () => await deploy('chrome');
8 |
9 | main();
10 |
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/firefox/deploy.js:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env node
2 |
3 | 'use strict';
4 |
5 | const deploy = require('../deploy');
6 |
7 | const main = async () => await deploy('firefox');
8 |
9 | main();
10 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/WarnIfLegacyBackendDetected.css:
--------------------------------------------------------------------------------
1 | .Command {
2 | background-color: var(--color-dimmest);
3 | padding: 0.25rem 0.5rem;
4 | display: block;
5 | border-radius: 0.125rem;
6 | }
7 |
--------------------------------------------------------------------------------
/scripts/perf-counters/Makefile:
--------------------------------------------------------------------------------
1 | build/jsc-perf: src/*
2 | mkdir -p build
3 | g++ -std=c++11 -I/usr/include/webkitgtk-1.0/ -ljavascriptcoregtk-1.0 src/jsc-perf.cpp src/hardware-counter.cpp src/thread-local.cpp -o build/jsc-perf
4 |
--------------------------------------------------------------------------------
/fixtures/packaging/rjs/dev/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/fixtures/packaging/rjs/prod/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/CONTRIBUTING.md:
--------------------------------------------------------------------------------
1 | # Contributing to React
2 |
3 | Want to contribute to React? There are a few things you need to know.
4 |
5 | We wrote a **[contribution guide](https://reactjs.org/docs/how-to-contribute.html)** to help you get started.
6 |
--------------------------------------------------------------------------------
/fixtures/flight/src/ServerState.js:
--------------------------------------------------------------------------------
1 | let serverState = 'Hello World';
2 |
3 | export function setServerState(message) {
4 | serverState = message;
5 | }
6 |
7 | export function getServerState() {
8 | return serverState;
9 | }
10 |
--------------------------------------------------------------------------------
/fixtures/packaging/rjs/dev/input.js:
--------------------------------------------------------------------------------
1 | require(['react', 'react-dom'], function (React, ReactDOM) {
2 | ReactDOM.render(
3 | React.createElement('h1', null, 'Hello World!'),
4 | document.getElementById('container')
5 | );
6 | });
7 |
--------------------------------------------------------------------------------
/fixtures/packaging/rjs/prod/input.js:
--------------------------------------------------------------------------------
1 | require(['react', 'react-dom'], function (React, ReactDOM) {
2 | ReactDOM.render(
3 | React.createElement('h1', null, 'Hello World!'),
4 | document.getElementById('container')
5 | );
6 | });
7 |
--------------------------------------------------------------------------------
/packages/react-devtools-shell/src/app/InspectableElements/UseMemoCache.js:
--------------------------------------------------------------------------------
1 | import * as React from 'react';
2 |
3 | export default function UseMemoCache(): React.Node {
4 | React.unstable_useMemoCache(1);
5 |
6 | return null;
7 | }
8 |
--------------------------------------------------------------------------------
/fixtures/flight-esm/src/ServerState.js:
--------------------------------------------------------------------------------
1 | let serverState = 'Hello World';
2 |
3 | export function setServerState(message) {
4 | serverState = message;
5 | }
6 |
7 | export function getServerState() {
8 | return serverState;
9 | }
10 |
--------------------------------------------------------------------------------
/fixtures/packaging/browserify/dev/input.js:
--------------------------------------------------------------------------------
1 | var React = require('react');
2 | var ReactDOM = require('react-dom');
3 |
4 | ReactDOM.render(
5 | React.createElement('h1', null, 'Hello World!'),
6 | document.getElementById('container')
7 | );
8 |
--------------------------------------------------------------------------------
/fixtures/packaging/brunch/dev/input.js:
--------------------------------------------------------------------------------
1 | var React = require('react');
2 | var ReactDOM = require('react-dom');
3 |
4 | ReactDOM.render(
5 | React.createElement('h1', null, 'Hello World!'),
6 | document.getElementById('container')
7 | );
8 |
--------------------------------------------------------------------------------
/fixtures/packaging/brunch/prod/input.js:
--------------------------------------------------------------------------------
1 | var React = require('react');
2 | var ReactDOM = require('react-dom');
3 |
4 | ReactDOM.render(
5 | React.createElement('h1', null, 'Hello World!'),
6 | document.getElementById('container')
7 | );
8 |
--------------------------------------------------------------------------------
/fixtures/packaging/systemjs-builder/dev/input.js:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import ReactDOM from 'react-dom';
3 |
4 | ReactDOM.render(
5 | React.createElement('h1', null, 'Hello World!'),
6 | document.getElementById('container')
7 | );
8 |
--------------------------------------------------------------------------------
/fixtures/packaging/webpack/dev/input.js:
--------------------------------------------------------------------------------
1 | var React = require('react');
2 | var ReactDOM = require('react-dom');
3 |
4 | ReactDOM.render(
5 | React.createElement('h1', null, 'Hello World!'),
6 | document.getElementById('container')
7 | );
8 |
--------------------------------------------------------------------------------
/fixtures/packaging/webpack/prod/input.js:
--------------------------------------------------------------------------------
1 | var React = require('react');
2 | var ReactDOM = require('react-dom');
3 |
4 | ReactDOM.render(
5 | React.createElement('h1', null, 'Hello World!'),
6 | document.getElementById('container')
7 | );
8 |
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/main.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/Components/ExpandCollapseToggle.css:
--------------------------------------------------------------------------------
1 | .ExpandCollapseToggle {
2 | flex: 0 0 1rem;
3 | width: 1rem;
4 | height: 1rem;
5 | padding: 0;
6 | color: var(--color-expand-collapse-toggle);
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-reconciler/src/__tests__/__snapshots__/ReactHooks-test.internal.js.snap:
--------------------------------------------------------------------------------
1 | // Jest Snapshot v1, https://goo.gl/fbAQLP
2 |
3 | exports[`ReactHooks works with ReactDOMServer calls inside a component 1`] = `"hello
0bye
"`;
4 |
--------------------------------------------------------------------------------
/packages/react/npm/index.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/fixtures/art/app.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | var React = require('react');
4 | var ReactDOM = require('react-dom');
5 | var VectorWidget = require('./VectorWidget');
6 |
7 | ReactDOM.render(, document.getElementById('container'));
8 |
--------------------------------------------------------------------------------
/fixtures/packaging/browserify/prod/input.js:
--------------------------------------------------------------------------------
1 | var React = require('react');
2 | var ReactDOM = require('react-dom');
3 |
4 | ReactDOM.render(
5 | React.createElement('h1', null, 'Hello World!'),
6 | document.getElementById('container')
7 | );
8 |
--------------------------------------------------------------------------------
/fixtures/packaging/brunch/dev/app/initialize.js:
--------------------------------------------------------------------------------
1 | var React = require('react');
2 | var ReactDOM = require('react-dom');
3 |
4 | ReactDOM.render(
5 | React.createElement('h1', null, 'Hello World!'),
6 | document.getElementById('container')
7 | );
8 |
--------------------------------------------------------------------------------
/fixtures/packaging/systemjs-builder/prod/input.js:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import ReactDOM from 'react-dom';
3 |
4 | ReactDOM.render(
5 | React.createElement('h1', null, 'Hello World!'),
6 | document.getElementById('container')
7 | );
8 |
--------------------------------------------------------------------------------
/fixtures/packaging/webpack-alias/dev/input.js:
--------------------------------------------------------------------------------
1 | var React = require('react');
2 | var ReactDOM = require('react-dom');
3 |
4 | ReactDOM.render(
5 | React.createElement('h1', null, 'Hello World!'),
6 | document.getElementById('container')
7 | );
8 |
--------------------------------------------------------------------------------
/fixtures/packaging/webpack-alias/prod/input.js:
--------------------------------------------------------------------------------
1 | var React = require('react');
2 | var ReactDOM = require('react-dom');
3 |
4 | ReactDOM.render(
5 | React.createElement('h1', null, 'Hello World!'),
6 | document.getElementById('container')
7 | );
8 |
--------------------------------------------------------------------------------
/fixtures/packaging/brunch/prod/app/initialize.js:
--------------------------------------------------------------------------------
1 | var React = require('react');
2 | var ReactDOM = require('react-dom');
3 |
4 | ReactDOM.render(
5 | React.createElement('h1', null, 'Hello World!'),
6 | document.getElementById('container')
7 | );
8 |
--------------------------------------------------------------------------------
/packages/react-art/npm/index.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-art.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-art.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-is/npm/index.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-is.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-is.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/scheduler/npm/index.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/scheduler.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/scheduler.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/jest-react/npm/index.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/jest-react.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/jest-react.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-cache/npm/index.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-cache.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-cache.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/Components/InspectedElementBadges.css:
--------------------------------------------------------------------------------
1 | .Root {
2 | padding: 0.25rem;
3 | user-select: none;
4 | display: inline-flex;
5 | }
6 |
7 | .Root *:not(:first-child) {
8 | margin-left: 0.25rem;
9 | }
10 |
--------------------------------------------------------------------------------
/packages/react-server-dom-esm/npm/server.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | throw new Error(
4 | 'The React Server Writer cannot be used outside a react-server environment. ' +
5 | 'You must configure Node.js using the `--conditions react-server` flag.'
6 | );
7 |
--------------------------------------------------------------------------------
/fixtures/packaging/rjs/dev/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "private": true,
3 | "name": "rjs-dev-fixture",
4 | "dependencies": {
5 | "requirejs": "^2.3.2"
6 | },
7 | "scripts": {
8 | "build": "rm -f output.js && r.js -o config.js"
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/fixtures/packaging/rjs/prod/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "private": true,
3 | "name": "rjs-prod-fixture",
4 | "dependencies": {
5 | "requirejs": "^2.3.2"
6 | },
7 | "scripts": {
8 | "build": "rm -f output.js && r.js -o config.js"
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/npm/server.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | throw new Error(
4 | 'The React Server Writer cannot be used outside a react-server environment. ' +
5 | 'You must configure Node.js using the `--conditions react-server` flag.'
6 | );
7 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/npm/server.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | throw new Error(
4 | 'The React Server Writer cannot be used outside a react-server environment. ' +
5 | 'You must configure Node.js using the `--conditions react-server` flag.'
6 | );
7 |
--------------------------------------------------------------------------------
/packages/react-server/npm/index.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-server.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-server.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/netlify.toml:
--------------------------------------------------------------------------------
1 | [build]
2 | base = ""
3 | publish = "fixtures/dom/build"
4 | command = "yarn build --type=UMD_DEV && cd fixtures/dom/ && yarn && yarn predev && yarn build"
5 |
6 | [[redirects]]
7 | from = "/*"
8 | to = "/index.html"
9 | status = 200
10 |
--------------------------------------------------------------------------------
/packages/react-reconciler/npm/index.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-reconciler.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-reconciler.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react/npm/jsx-runtime.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-jsx-runtime.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-jsx-runtime.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/scheduler/npm/index.native.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/scheduler.native.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/scheduler.native.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/use-subscription/npm/index.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/use-subscription.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/use-subscription.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/fixtures/attribute-behavior/src/App.test.js:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import ReactDOM from 'react-dom';
3 | import App from './App';
4 |
5 | it('renders without crashing', () => {
6 | const div = document.createElement('div');
7 | ReactDOM.render(, div);
8 | });
9 |
--------------------------------------------------------------------------------
/fixtures/fiber-debugger/.gitignore:
--------------------------------------------------------------------------------
1 | # See http://help.github.com/ignore-files/ for more about ignoring files.
2 |
3 | # dependencies
4 | node_modules
5 |
6 | # testing
7 | coverage
8 |
9 | # production
10 | build
11 |
12 | # misc
13 | .DS_Store
14 | npm-debug.log
15 |
--------------------------------------------------------------------------------
/fixtures/packaging/webpack/dev/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "private": true,
3 | "name": "webpack-dev-fixture",
4 | "dependencies": {
5 | "webpack": "^1.14.0"
6 | },
7 | "scripts": {
8 | "build": "rm -f output.js && webpack --config config.js"
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/fixtures/packaging/webpack/prod/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "private": true,
3 | "name": "webpack-prod-fixture",
4 | "dependencies": {
5 | "webpack": "^1.14.0"
6 | },
7 | "scripts": {
8 | "build": "rm -f output.js && webpack --config config.js"
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/packages/react-client/npm/flight.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-client-flight.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-client-flight.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-debug-tools/npm/index.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-debug-tools.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-debug-tools.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/Profiler/CommitFlamegraph.css:
--------------------------------------------------------------------------------
1 | .Container {
2 | width: 100%;
3 | flex: 1;
4 | padding: 0.5rem;
5 | }
6 |
7 | .PatternPath {
8 | stroke: var(--color-commit-did-not-render-pattern);
9 | stroke-width: 1;
10 | }
11 |
--------------------------------------------------------------------------------
/packages/react-refresh/npm/babel.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-refresh-babel.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-refresh-babel.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-server/npm/flight.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-server-flight.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-server-flight.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/fixtures/flight/src/cjs/Note.js:
--------------------------------------------------------------------------------
1 | 'use client';
2 |
3 | var React = require('react');
4 |
5 | function Note() {
6 | return 'This component was exported on a commonJS module and imported into ESM as a named import.';
7 | }
8 |
9 | module.exports = {
10 | Note,
11 | };
12 |
--------------------------------------------------------------------------------
/fixtures/nesting/src/legacy/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "private": true,
3 | "name": "react-nesting-example-legacy",
4 | "dependencies": {
5 | "react": "16.8",
6 | "react-dom": "16.8",
7 | "react-redux": "4.4.10",
8 | "react-router-dom": "5.2.0"
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/fixtures/packaging/systemjs-builder/dev/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "private": true,
3 | "name": "systemjs-dev-fixture",
4 | "dependencies": {
5 | "systemjs-builder": "^0.15.34"
6 | },
7 | "scripts": {
8 | "build": "rm -f output.js && node build.js"
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/README.md:
--------------------------------------------------------------------------------
1 | This directory contains code shared between several DevTools packages:
2 | * /packages/react-devtools-core
3 | * /packages/react-devtools-extensions
4 | * /packages/react-devtools-inline
5 |
6 | It is not published or released anywhere directly.
--------------------------------------------------------------------------------
/packages/react-dom/npm/test-utils.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-dom-test-utils.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-dom-test-utils.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-noop-renderer/npm/index.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-noop-renderer.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-noop-renderer.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-refresh/npm/runtime.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-refresh-runtime.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-refresh-runtime.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-test-renderer/npm/index.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-test-renderer.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-test-renderer.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react/npm/jsx-dev-runtime.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-jsx-dev-runtime.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-jsx-dev-runtime.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react/npm/react.shared-subset.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react.shared-subset.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react.shared-subset.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react/npm/unstable-cache.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-unstable-cache.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-unstable-cache.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/fixtures/packaging/systemjs-builder/prod/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "private": true,
3 | "name": "systemjs-prod-fixture",
4 | "dependencies": {
5 | "systemjs-builder": "^0.15.34"
6 | },
7 | "scripts": {
8 | "build": "rm -f output.js && node build.js"
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/fixtures/packaging/webpack-alias/dev/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "private": true,
3 | "name": "webpack-alias-dev-fixture",
4 | "dependencies": {
5 | "webpack": "^1.14.0"
6 | },
7 | "scripts": {
8 | "build": "rm -f output.js && webpack --config config.js"
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/fixtures/packaging/webpack/dev/config.js:
--------------------------------------------------------------------------------
1 | var path = require('path');
2 |
3 | module.exports = {
4 | entry: './input',
5 | output: {
6 | filename: 'output.js',
7 | },
8 | resolve: {
9 | root: path.resolve('../../../../build/oss-experimental/'),
10 | },
11 | };
12 |
--------------------------------------------------------------------------------
/packages/scheduler/npm/unstable_mock.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/scheduler-unstable_mock.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/scheduler-unstable_mock.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/fixtures/fiber-debugger/src/index.css:
--------------------------------------------------------------------------------
1 | html, body {
2 | margin: 0;
3 | padding: 0;
4 | font-family: sans-serif;
5 | height: 100vh;
6 | cursor: -webkit-grab; cursor: -moz-grab;
7 | }
8 |
9 | #root {
10 | height: 100vh;
11 | }
12 |
13 | * {
14 | box-sizing: border-box;
15 | }
--------------------------------------------------------------------------------
/fixtures/legacy-jsx-runtimes/react-14/jsx-runtime.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-jsx-runtime.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-jsx-runtime.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/fixtures/legacy-jsx-runtimes/react-15/jsx-runtime.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-jsx-runtime.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-jsx-runtime.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/fixtures/legacy-jsx-runtimes/react-16/jsx-runtime.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-jsx-runtime.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-jsx-runtime.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/fixtures/legacy-jsx-runtimes/react-17/jsx-runtime.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-jsx-runtime.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-jsx-runtime.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/fixtures/packaging/webpack-alias/prod/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "private": true,
3 | "name": "webpack-alias-prod-fixture",
4 | "dependencies": {
5 | "webpack": "^1.14.0"
6 | },
7 | "scripts": {
8 | "build": "rm -f output.js && webpack --config config.js"
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/packages/eslint-plugin-react-hooks/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | */
7 |
8 | export * from './src/index';
9 |
--------------------------------------------------------------------------------
/packages/react-debug-tools/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | */
7 |
8 | export * from './src/ReactDebugTools';
9 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/Components/EditableName.css:
--------------------------------------------------------------------------------
1 | .Input {
2 | flex: 0 1 auto;
3 | box-shadow: 0px 1px 3px transparent;
4 | color: var(--color-text);
5 | }
6 | .Input:focus {
7 | color: var(--color-text);
8 | box-shadow: 0px 1px 3px var(--color-shadow);
9 | }
--------------------------------------------------------------------------------
/packages/react-refresh/runtime.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | */
7 |
8 | export * from './src/ReactFreshRuntime';
9 |
--------------------------------------------------------------------------------
/scripts/print-warnings/README.md:
--------------------------------------------------------------------------------
1 | We use this script to extract all messages from `warning()` calls. They don't get substituted with anything in the source or the build. We only do this so we can have a copy of these messages in our internal repository and can spot accidental changes to them.
2 |
--------------------------------------------------------------------------------
/fixtures/packaging/rjs/dev/yarn.lock:
--------------------------------------------------------------------------------
1 | # THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
2 | # yarn lockfile v1
3 |
4 |
5 | requirejs@^2.3.2:
6 | version "2.3.5"
7 | resolved "https://registry.yarnpkg.com/requirejs/-/requirejs-2.3.5.tgz#617b9acbbcb336540ef4914d790323a8d4b861b0"
8 |
--------------------------------------------------------------------------------
/fixtures/packaging/rjs/prod/yarn.lock:
--------------------------------------------------------------------------------
1 | # THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
2 | # yarn lockfile v1
3 |
4 |
5 | requirejs@^2.3.2:
6 | version "2.3.5"
7 | resolved "https://registry.yarnpkg.com/requirejs/-/requirejs-2.3.5.tgz#617b9acbbcb336540ef4914d790323a8d4b861b0"
8 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/Components/NewKeyValue.css:
--------------------------------------------------------------------------------
1 | .NewKeyValue {
2 | white-space: nowrap;
3 | display: flex;
4 | align-items: center;
5 | }
6 |
7 | .EditableName {
8 | margin-left: 1rem;
9 | }
10 |
11 | .EditableValue {
12 | min-width: 1rem;
13 | }
14 |
--------------------------------------------------------------------------------
/packages/react-dom/npm/react-dom.shared-subset.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-dom.shared-subset.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-dom.shared-subset.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-noop-renderer/npm/server.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-noop-renderer-server.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-noop-renderer-server.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-reconciler/npm/constants.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-reconciler-constants.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-reconciler-constants.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/use-sync-external-store/npm/index.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/use-sync-external-store.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/use-sync-external-store.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/scripts/perf-counters/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "perf-counters",
3 | "version": "0.1.2",
4 | "description": "Lightweight bindings to Linux perf event counters.",
5 | "main": "index.js",
6 | "license": "MIT",
7 | "dependencies": {
8 | "bindings": "^1.2.1"
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/fixtures/legacy-jsx-runtimes/react-14/jsx-dev-runtime.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-jsx-dev-runtime.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-jsx-dev-runtime.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/fixtures/legacy-jsx-runtimes/react-15/jsx-dev-runtime.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-jsx-dev-runtime.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-jsx-dev-runtime.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/fixtures/legacy-jsx-runtimes/react-16/jsx-dev-runtime.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-jsx-dev-runtime.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-jsx-dev-runtime.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/fixtures/legacy-jsx-runtimes/react-17/jsx-dev-runtime.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-jsx-dev-runtime.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-jsx-dev-runtime.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/fixtures/nesting/src/modern/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "private": true,
3 | "name": "react-nesting-example-modern",
4 | "dependencies": {
5 | "react": "0.0.0-3d0895557",
6 | "react-dom": "0.0.0-3d0895557",
7 | "react-redux": "7.2.1",
8 | "react-router-dom": "5.2.0"
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/packages/react-client/README.md:
--------------------------------------------------------------------------------
1 | # react-client
2 |
3 | This is an experimental package for consuming custom React streaming models.
4 |
5 | **Its API is not as stable as that of React, React Native, or React DOM, and does not follow the common versioning scheme.**
6 |
7 | **Use it at your own risk.**
8 |
--------------------------------------------------------------------------------
/packages/react-debug-tools/README.md:
--------------------------------------------------------------------------------
1 | # react-debug-tools
2 |
3 | This is an experimental package for debugging React renderers.
4 |
5 | **Its API is not as stable as that of React, React Native, or React DOM, and does not follow the common versioning scheme.**
6 |
7 | **Use it at your own risk.**
8 |
--------------------------------------------------------------------------------
/packages/react-interactions/npm/drag.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-interactions-events/drag.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-interactions-events/drag.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-interactions/npm/tap.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-interactions-events/tap.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-interactions-events/tap.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-reconciler/npm/reflection.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-reconciler-reflection.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-reconciler-reflection.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-refresh/babel.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | */
7 |
8 | export {default} from './src/ReactFreshBabelPlugin';
9 |
--------------------------------------------------------------------------------
/packages/scheduler/npm/unstable_post_task.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/scheduler-unstable_post_task.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/scheduler-unstable_post_task.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-devtools-inline/src/hookNames.js:
--------------------------------------------------------------------------------
1 | /** @flow */
2 |
3 | import {
4 | parseHookNames,
5 | parseSourceAndMetadata,
6 | purgeCachedMetadata,
7 | } from 'react-devtools-shared/src/hooks/parseHookNames';
8 |
9 | export {parseHookNames, parseSourceAndMetadata, purgeCachedMetadata};
10 |
--------------------------------------------------------------------------------
/packages/react-interactions/npm/focus.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-interactions-events/focus.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-interactions-events/focus.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-interactions/npm/hover.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-interactions-events/hover.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-interactions-events/hover.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-interactions/npm/input.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-interactions-events/input.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-interactions-events/input.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-interactions/npm/press.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-interactions-events/press.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-interactions-events/press.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-interactions/npm/scroll.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-interactions-events/scroll.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-interactions-events/scroll.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-interactions/npm/swipe.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-interactions-events/swipe.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-interactions-events/swipe.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/fixtures/eslint/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "private": true,
3 | "name": "eslint-playground",
4 | "dependencies": {
5 | "eslint": "4.1.0",
6 | "eslint-plugin-react-hooks": "link:./proxy"
7 | },
8 | "scripts": {
9 | "start": "./watch.sh",
10 | "lint": "eslint index.js"
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/packages/react-art/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactART';
11 |
--------------------------------------------------------------------------------
/packages/react-dom/npm/server-rendering-stub.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-dom-server-rendering-stub.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-dom-server-rendering-stub.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-dom/server.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './server.node';
11 |
--------------------------------------------------------------------------------
/packages/react-dom/static.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './static.node';
11 |
--------------------------------------------------------------------------------
/packages/react-noop-renderer/npm/persistent.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-noop-renderer-persistent.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-noop-renderer-persistent.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-server/README.md:
--------------------------------------------------------------------------------
1 | # react-server
2 |
3 | This is an experimental package for creating custom React streaming server renderers.
4 |
5 | **Its API is not as stable as that of React, React Native, or React DOM, and does not follow the common versioning scheme.**
6 |
7 | **Use it at your own risk.**
8 |
--------------------------------------------------------------------------------
/packages/use-sync-external-store/npm/shim/index.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('../cjs/use-sync-external-store-shim.production.min.js');
5 | } else {
6 | module.exports = require('../cjs/use-sync-external-store-shim.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/scripts/git/pre-commit:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 | #
3 | # To enable this hook, symlink or copy this file to .git/hooks/pre-commit.
4 |
5 | # Redirect output to stderr.
6 | exec 1>&2
7 |
8 | git diff --cached --name-only --diff-filter=ACMRTUB | \
9 | grep '\.js$' | \
10 | xargs ./node_modules/.bin/eslint --
11 |
--------------------------------------------------------------------------------
/packages/jest-react/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | */
7 |
8 | 'use strict';
9 |
10 | export * from './src/JestReact';
11 |
--------------------------------------------------------------------------------
/packages/react-art/Circle.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export {default} from './npm/Circle';
11 |
--------------------------------------------------------------------------------
/packages/react-art/Wedge.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export {default} from './npm/Wedge';
11 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/hooks/__tests__/__source__/__untransformed__/README.md:
--------------------------------------------------------------------------------
1 | The JavaScript source files in this directory are not linted or pre-processed in any way. This is intentional, since they are used by the `parseHookNames-test` to test the behavior of "uncompiled" JavaScript (without source maps).
--------------------------------------------------------------------------------
/packages/react-noop-renderer/npm/flight-client.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-noop-renderer-flight-client.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-noop-renderer-flight-client.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-noop-renderer/npm/flight-server.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-noop-renderer-flight-server.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-noop-renderer-flight-server.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-server-dom-esm/npm/client.node.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-server-dom-esm-client.node.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-server-dom-esm-client.node.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-server-dom-esm/npm/server.node.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-server-dom-esm-server.node.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-server-dom-esm-server.node.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/use-sync-external-store/README.md:
--------------------------------------------------------------------------------
1 | # use-sync-external-store
2 |
3 | Backwards-compatible shim for [`React.useSyncExternalStore`](https://reactjs.org/docs/hooks-reference.html#usesyncexternalstore). Works with any React that supports Hooks.
4 |
5 | See also https://github.com/reactwg/react-18/discussions/86.
6 |
--------------------------------------------------------------------------------
/packages/react-art/Rectangle.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export {default} from './npm/Rectangle';
11 |
--------------------------------------------------------------------------------
/packages/react-client/flight.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFlightClient';
11 |
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/src/main/debounce.js:
--------------------------------------------------------------------------------
1 | function debounce(fn, timeout) {
2 | let executionTimeoutId = null;
3 |
4 | return (...args) => {
5 | clearTimeout(executionTimeoutId);
6 | executionTimeoutId = setTimeout(fn, timeout, ...args);
7 | };
8 | }
9 |
10 | export default debounce;
11 |
--------------------------------------------------------------------------------
/packages/react-devtools-shell/src/app/ToDoList/List.css:
--------------------------------------------------------------------------------
1 | .Input {
2 | font-size: 1rem;
3 | padding: 0.25rem;
4 | }
5 |
6 | .IconButton {
7 | padding: 0.25rem;
8 | border: none;
9 | background: none;
10 | cursor: pointer;
11 | }
12 |
13 | .List {
14 | margin: 0.5rem 0 0;
15 | padding: 0;
16 | }
17 |
--------------------------------------------------------------------------------
/packages/react-noop-renderer/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactNoop';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-esm/client.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './client.browser';
11 |
--------------------------------------------------------------------------------
/packages/react-server/flight.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFlightServer';
11 |
--------------------------------------------------------------------------------
/packages/react-server/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFizzServer';
11 |
--------------------------------------------------------------------------------
/packages/scheduler/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | */
7 |
8 | 'use strict';
9 |
10 | export * from './src/forks/Scheduler';
11 |
--------------------------------------------------------------------------------
/scripts/jest/setupGlobal.js:
--------------------------------------------------------------------------------
1 | /* eslint-disable */
2 |
3 | module.exports = () => {
4 | // can use beforeEach/afterEach or setupEnvironment.js in node >= 13: https://github.com/nodejs/node/pull/20026
5 | // jest's `setupFiles` is too late: https://stackoverflow.com/a/56482581/3406963
6 | process.env.TZ = 'UTC';
7 | };
8 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/ContextMenu/ContextMenu.css:
--------------------------------------------------------------------------------
1 | .ContextMenu {
2 | position: absolute;
3 | background-color: var(--color-context-background);
4 | box-shadow: 1px 1px 2px var(--color-shadow);
5 | border-radius: 0.25rem;
6 | overflow: hidden;
7 | z-index: 10000002;
8 | user-select: none;
9 | }
--------------------------------------------------------------------------------
/packages/react-interactions/npm/press-legacy.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-interactions-events/press-legacy.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-interactions-events/press-legacy.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-noop-renderer/server.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactNoopServer';
11 |
--------------------------------------------------------------------------------
/packages/react-reconciler/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFiberReconciler';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-esm/npm/client.browser.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-server-dom-esm-client.browser.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-server-dom-esm-client.browser.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/client.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './client.browser';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/npm/client.edge.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-server-dom-webpack-client.edge.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-server-dom-webpack-client.edge.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/npm/client.node.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-server-dom-webpack-client.node.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-server-dom-webpack-client.node.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/npm/server.edge.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-server-dom-webpack-server.edge.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-server-dom-webpack-server.edge.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/npm/server.node.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-server-dom-webpack-server.node.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-server-dom-webpack-server.node.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-test-renderer/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactTestRenderer';
11 |
--------------------------------------------------------------------------------
/packages/react-dom/test-utils.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/test-utils/ReactTestUtils';
11 |
--------------------------------------------------------------------------------
/packages/react-dom/unstable_testing.stable.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './index.stable.js';
11 |
--------------------------------------------------------------------------------
/packages/react-is/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | 'use strict';
11 |
12 | export * from './src/ReactIs';
13 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/client.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './client.browser';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/npm/client.edge.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-server-dom-turbopack-client.edge.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-server-dom-turbopack-client.edge.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/npm/client.node.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-server-dom-turbopack-client.node.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-server-dom-turbopack-client.node.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/npm/server.edge.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-server-dom-turbopack-server.edge.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-server-dom-turbopack-server.edge.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/npm/server.node.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-server-dom-turbopack-server.node.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-server-dom-turbopack-server.node.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react/jsx-runtime.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 | export {Fragment, jsx, jsxs} from './src/jsx/ReactJSX';
10 |
--------------------------------------------------------------------------------
/packages/react/react.shared-subset.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and its affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactSharedSubset';
11 |
--------------------------------------------------------------------------------
/packages/scheduler/unstable_mock.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | */
7 |
8 | 'use strict';
9 |
10 | export * from './src/forks/SchedulerMock';
11 |
--------------------------------------------------------------------------------
/packages/use-sync-external-store/npm/shim/index.native.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('../cjs/use-sync-external-store-shim.native.production.min.js');
5 | } else {
6 | module.exports = require('../cjs/use-sync-external-store-shim.native.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/use-sync-external-store/npm/with-selector.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/use-sync-external-store-with-selector.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/use-sync-external-store-with-selector.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-dom-bindings/src/server/fizz-instruction-set/ReactDOMFizzInlineCompleteSegment.js:
--------------------------------------------------------------------------------
1 | import {completeSegment} from './ReactDOMFizzInstructionSetInlineSource';
2 |
3 | // This is a string so Closure's advanced compilation mode doesn't mangle it.
4 | // eslint-disable-next-line dot-notation
5 | window['$RS'] = completeSegment;
6 |
--------------------------------------------------------------------------------
/packages/react-noop-renderer/persistent.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactNoopPersistent';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/npm/client.browser.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-server-dom-webpack-client.browser.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-server-dom-webpack-client.browser.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/npm/server.browser.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-server-dom-webpack-server.browser.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-server-dom-webpack-server.browser.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-test-renderer/shallow.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export {default} from 'react-shallow-renderer';
11 |
--------------------------------------------------------------------------------
/packages/react/jsx-dev-runtime.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export {Fragment, jsxDEV} from './src/jsx/ReactJSX';
11 |
--------------------------------------------------------------------------------
/fixtures/flight/src/Dynamic.js:
--------------------------------------------------------------------------------
1 | 'use client';
2 |
3 | import * as React from 'react';
4 |
5 | export function Dynamic() {
6 | return (
7 |
8 | This client component should be loaded in a single chunk even when it is
9 | used as both a client reference and as a dynamic import.
10 |
11 | );
12 | }
13 |
--------------------------------------------------------------------------------
/fixtures/legacy-jsx-runtimes/README.md:
--------------------------------------------------------------------------------
1 | # Legacy JSX Runtimes
2 |
3 | This is an internal testing fixture for the special JSX runtime versions released for 0.14, 15, and 16.
4 |
5 | They are checked into the corresponding `react-*/cjs/*` folders.
6 |
7 | Run the full regression suite:
8 |
9 | ```
10 | yarn
11 | yarn test
12 | ```
13 |
--------------------------------------------------------------------------------
/fixtures/legacy-jsx-runtimes/babel.config.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | presets: [
3 | [
4 | '@babel/react',
5 | {
6 | runtime: 'automatic',
7 | development: process.env.BABEL_ENV === 'development',
8 | },
9 | ],
10 | ],
11 | plugins: ['@babel/plugin-transform-modules-commonjs'],
12 | };
13 |
--------------------------------------------------------------------------------
/packages/react-cache/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | 'use strict';
11 |
12 | export * from './src/ReactCacheOld';
13 |
--------------------------------------------------------------------------------
/packages/react-dom-bindings/src/server/fizz-instruction-set/ReactDOMFizzInlineCompleteBoundary.js:
--------------------------------------------------------------------------------
1 | import {completeBoundary} from './ReactDOMFizzInstructionSetInlineSource';
2 |
3 | // This is a string so Closure's advanced compilation mode doesn't mangle it.
4 | // eslint-disable-next-line dot-notation
5 | window['$RC'] = completeBoundary;
6 |
--------------------------------------------------------------------------------
/packages/react-noop-renderer/flight-client.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactNoopFlightClient';
11 |
--------------------------------------------------------------------------------
/packages/react-noop-renderer/flight-server.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactNoopFlightServer';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-esm/client.node.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFlightDOMClientNode';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-esm/server.node.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFlightDOMServerNode';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/npm/client.browser.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-server-dom-turbopack-client.browser.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-server-dom-turbopack-client.browser.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/npm/server.browser.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-server-dom-turbopack-server.browser.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-server-dom-turbopack-server.browser.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-suspense-test-utils/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactSuspenseTestUtils';
11 |
--------------------------------------------------------------------------------
/packages/scheduler/unstable_post_task.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | */
7 |
8 | 'use strict';
9 |
10 | export * from './src/forks/SchedulerPostTask';
11 |
--------------------------------------------------------------------------------
/packages/shared/assign.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | const assign = Object.assign;
11 |
12 | export default assign;
13 |
--------------------------------------------------------------------------------
/packages/react-dom/src/server/react-dom-server.bun.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './ReactDOMFizzServerBun.js';
11 |
--------------------------------------------------------------------------------
/packages/react-interactions/events/focus.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/dom/create-event-handle/Focus';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-esm/client.browser.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFlightDOMClientBrowser';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/client.edge.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFlightDOMClientEdge';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/client.node.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFlightDOMClientNode';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/server.edge.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFlightDOMServerEdge';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/server.node.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFlightDOMServerNode';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/client.edge.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFlightDOMClientEdge';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/client.node.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFlightDOMClientNode';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/server.edge.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFlightDOMServerEdge';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/server.node.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFlightDOMServerNode';
11 |
--------------------------------------------------------------------------------
/packages/use-subscription/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | 'use strict';
11 |
12 | export * from './src/useSubscription';
13 |
--------------------------------------------------------------------------------
/packages/use-sync-external-store/npm/shim/with-selector.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('../cjs/use-sync-external-store-shim/with-selector.production.min.js');
5 | } else {
6 | module.exports = require('../cjs/use-sync-external-store-shim/with-selector.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/scripts/authors:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env sh
2 |
3 | # Generate an AUTHORS file based on the output of git shortlog. It uses ABC
4 | # order, strips out leading spaces and numbers, then filters out specific
5 | # authors.
6 |
7 | git shortlog -se \
8 | | perl -spe 's/^\s+\d+\s+//' \
9 | | sed -e '/^CommitSyncScript.*$/d' \
10 | > AUTHORS
11 |
--------------------------------------------------------------------------------
/packages/react-dom-bindings/src/server/fizz-instruction-set/ReactDOMFizzInlineClientRenderBoundary.js:
--------------------------------------------------------------------------------
1 | import {clientRenderBoundary} from './ReactDOMFizzInstructionSetInlineSource';
2 |
3 | // This is a string so Closure's advanced compilation mode doesn't mangle it.
4 | // eslint-disable-next-line dot-notation
5 | window['$RX'] = clientRenderBoundary;
6 |
--------------------------------------------------------------------------------
/packages/react-server-dom-esm/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | throw new Error('Use react-server-dom-esm/client instead.');
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/client.browser.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFlightDOMClientBrowser';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/plugin.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export {default} from './src/ReactFlightWebpackPlugin';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/server.browser.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFlightDOMServerBrowser';
11 |
--------------------------------------------------------------------------------
/scripts/error-codes/Types.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 | 'use strict';
10 |
11 | export type ErrorMap = {[id: string]: string, ...};
12 |
--------------------------------------------------------------------------------
/fixtures/ssr/src/components/Page.css:
--------------------------------------------------------------------------------
1 | .link {
2 | font-weight: bold;
3 | cursor: pointer;
4 | }
5 | .light-box {
6 | margin: 10px 0;
7 | padding: 10px;
8 | background-color: #CCCCCC;
9 | color: #333333;
10 | }
11 | .dark-box {
12 | margin: 10px 0;
13 | padding: 10px;
14 | background-color: #333333;
15 | color: #CCCCCC;
16 | }
17 |
--------------------------------------------------------------------------------
/fixtures/ssr2/src/Layout.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | */
8 |
9 | export default function Layout({children}) {
10 | return {children};
11 | }
12 |
--------------------------------------------------------------------------------
/packages/react-dom/npm/static.edge.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | var s;
4 | if (process.env.NODE_ENV === 'production') {
5 | s = require('./cjs/react-dom-server.edge.production.min.js');
6 | } else {
7 | s = require('./cjs/react-dom-server.edge.development.js');
8 | }
9 |
10 | exports.version = s.version;
11 | exports.prerender = s.prerender;
12 |
--------------------------------------------------------------------------------
/packages/react-dom/static.edge.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export {prerender, version} from './src/server/react-dom-server.edge';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/client.browser.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFlightDOMClientBrowser';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/client.node.unbundled.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFlightDOMClientNode';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/server.browser.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFlightDOMServerBrowser';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/server.node.unbundled.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFlightDOMServerNode';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/client.node.unbundled.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFlightDOMClientNode';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | throw new Error('Use react-server-dom-webpack/client instead.');
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/npm/client.node.unbundled.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-server-dom-webpack-client.node.unbundled.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-server-dom-webpack-client.node.unbundled.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/npm/server.node.unbundled.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-server-dom-webpack-server.node.unbundled.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-server-dom-webpack-server.node.unbundled.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/server.node.unbundled.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './src/ReactFlightDOMServerNode';
11 |
--------------------------------------------------------------------------------
/packages/scheduler/index.native.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | 'use strict';
11 |
12 | export * from './src/forks/SchedulerNative';
13 |
--------------------------------------------------------------------------------
/fixtures/eslint/README.md:
--------------------------------------------------------------------------------
1 | # ESLint Playground Fixture
2 |
3 | This is an internal playground for quick iteration on our lint rules inside an IDE like VSCode.
4 |
5 | See instructions in `./index.js` in this directory.
6 |
7 | 
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/isArray.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | const isArray = Array.isArray;
11 |
12 | export default isArray;
13 |
--------------------------------------------------------------------------------
/packages/react-dom/npm/static.browser.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | var s;
4 | if (process.env.NODE_ENV === 'production') {
5 | s = require('./cjs/react-dom-server.browser.production.min.js');
6 | } else {
7 | s = require('./cjs/react-dom-server.browser.development.js');
8 | }
9 |
10 | exports.version = s.version;
11 | exports.prerender = s.prerender;
12 |
--------------------------------------------------------------------------------
/packages/react-dom/static.browser.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export {prerender, version} from './src/server/react-dom-server.browser';
11 |
--------------------------------------------------------------------------------
/packages/react-reconciler/constants.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | 'use strict';
11 |
12 | export * from './src/ReactReconcilerConstants';
13 |
--------------------------------------------------------------------------------
/packages/react-reconciler/reflection.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | 'use strict';
11 |
12 | export * from './src/ReactFiberTreeReflection';
13 |
--------------------------------------------------------------------------------
/packages/react-reconciler/src/forks/ReactFiberConfig.art.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from 'react-art/src/ReactFiberConfigART';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | throw new Error('Use react-server-dom-turbopack/client instead.');
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/npm/client.node.unbundled.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-server-dom-turbopack-client.node.unbundled.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-server-dom-turbopack-client.node.unbundled.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/npm/server.node.unbundled.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | if (process.env.NODE_ENV === 'production') {
4 | module.exports = require('./cjs/react-server-dom-turbopack-server.node.unbundled.production.min.js');
5 | } else {
6 | module.exports = require('./cjs/react-server-dom-turbopack-server.node.unbundled.development.js');
7 | }
8 |
--------------------------------------------------------------------------------
/packages/react-server/src/forks/ReactServerStreamConfig.dom-bun.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from '../ReactServerStreamConfigBun';
11 |
--------------------------------------------------------------------------------
/scripts/perf-counters/binding.gyp:
--------------------------------------------------------------------------------
1 | {
2 | "targets": [
3 | {
4 | "target_name": "perfcounters",
5 | "sources": [
6 | "src/hardware-counter.cpp",
7 | "src/perf-counters.cpp",
8 | "src/thread-local.cpp",
9 | ],
10 | "cflags": [
11 | "-Wno-sign-compare",
12 | ],
13 | },
14 | ],
15 | }
16 |
--------------------------------------------------------------------------------
/fixtures/eslint/.eslintrc.json:
--------------------------------------------------------------------------------
1 | {
2 | "root": true,
3 | "parserOptions": {
4 | "ecmaVersion": 8,
5 | "sourceType": "module",
6 | "ecmaFeatures": {
7 | "jsx": true
8 | }
9 | },
10 | "plugins": ["react-hooks"],
11 | "rules": {
12 | "react-hooks/rules-of-hooks": 2,
13 | "react-hooks/exhaustive-deps": 2
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/src/main/injectBackendManager.js:
--------------------------------------------------------------------------------
1 | /* global chrome */
2 |
3 | function injectBackendManager(tabId) {
4 | chrome.runtime.sendMessage({
5 | source: 'devtools-page',
6 | payload: {
7 | type: 'inject-backend-manager',
8 | tabId,
9 | },
10 | });
11 | }
12 |
13 | export default injectBackendManager;
14 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/UnsupportedVersionDialog.css:
--------------------------------------------------------------------------------
1 | .Row {
2 | display: flex;
3 | flex-direction: row;
4 | align-items: center;
5 | }
6 |
7 | .Title {
8 | font-size: var(--font-size-sans-large);
9 | margin-bottom: 0.5rem;
10 | }
11 |
12 | .ReleaseNotesLink {
13 | color: var(--color-button-active);
14 | }
--------------------------------------------------------------------------------
/packages/react-devtools-shell/src/app/ToDoList/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | import List from './List';
11 |
12 | export default List;
13 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/node-register.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | module.exports = require('./src/ReactFlightWebpackNodeRegister');
11 |
--------------------------------------------------------------------------------
/packages/react-server/src/forks/ReactServerStreamConfig.dom-edge.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from '../ReactServerStreamConfigEdge';
11 |
--------------------------------------------------------------------------------
/packages/react-server/src/forks/ReactServerStreamConfig.dom-node.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from '../ReactServerStreamConfigNode';
11 |
--------------------------------------------------------------------------------
/packages/use-sync-external-store/src/forks/isServerEnvironment.native.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export const isServerEnvironment = false;
11 |
--------------------------------------------------------------------------------
/fixtures/dom/src/index.js:
--------------------------------------------------------------------------------
1 | import './polyfills';
2 | import loadReact from './react-loader';
3 |
4 | loadReact()
5 | .then(() => import('./components/App'))
6 | .then(App => {
7 | const {React, ReactDOM} = window;
8 |
9 | ReactDOM.render(
10 | React.createElement(App.default),
11 | document.getElementById('root')
12 | );
13 | });
14 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/node-register.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | module.exports = require('./src/ReactFlightTurbopackNodeRegister');
11 |
--------------------------------------------------------------------------------
/packages/react-server/src/forks/ReactServerStreamConfig.dom-browser.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from '../ReactServerStreamConfigBrowser';
11 |
--------------------------------------------------------------------------------
/packages/shared/getPrototypeOf.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | const getPrototypeOf = Object.getPrototypeOf;
11 |
12 | export default getPrototypeOf;
13 |
--------------------------------------------------------------------------------
/fixtures/packaging/browserify/dev/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "private": true,
3 | "name": "browserify-dev-fixture",
4 | "dependencies": {
5 | "browserify": "^13.3.0"
6 | },
7 | "scripts": {
8 | "build": "rm -f output.js && browserify ./input.js -o output.js",
9 | "prebuild": "cp -r ../../../../build/oss-experimental/* ./node_modules/"
10 | }
11 | }
12 |
--------------------------------------------------------------------------------
/fixtures/ssr/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/packages/react-art/README.md:
--------------------------------------------------------------------------------
1 | # React ART
2 |
3 | React ART is a JavaScript library for drawing vector graphics using [React](https://github.com/facebook/react/).
4 |
5 | It provides declarative and reactive bindings to the [ART library](https://github.com/sebmarkbage/art/).
6 |
7 | Using the same declarative API you can render the output to either Canvas, SVG or VML (IE8).
8 |
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/deploy.edge.html:
--------------------------------------------------------------------------------
1 |
2 | - download extension
3 | - Double-click to extract
4 | - Navigate to
edge://extensions/
5 | - Enable "Developer mode"
6 | - Click "LOAD UNPACKED"
7 | - Select extracted extension folder (
ReactDevTools)
8 |
--------------------------------------------------------------------------------
/packages/react-dom/npm/static.node.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | var s;
4 | if (process.env.NODE_ENV === 'production') {
5 | s = require('./cjs/react-dom-server.node.production.min.js');
6 | } else {
7 | s = require('./cjs/react-dom-server.node.development.js');
8 | }
9 |
10 | exports.version = s.version;
11 | exports.prerenderToNodeStream = s.prerenderToNodeStream;
12 |
--------------------------------------------------------------------------------
/packages/react-reconciler/src/forks/ReactFiberConfig.dom.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from 'react-dom-bindings/src/client/ReactFiberConfigDOM';
11 |
--------------------------------------------------------------------------------
/packages/react-reconciler/src/forks/ReactFiberConfig.fabric.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from 'react-native-renderer/src/ReactFiberConfigFabric';
11 |
--------------------------------------------------------------------------------
/packages/react-reconciler/src/forks/ReactFiberConfig.native.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from 'react-native-renderer/src/ReactFiberConfigNative';
11 |
--------------------------------------------------------------------------------
/packages/react-reconciler/src/forks/ReactFiberConfig.test.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from 'react-test-renderer/src/ReactFiberConfigTestHost';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-esm/npm/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | 'use strict';
11 |
12 | throw new Error('Use react-server-dom-esm/client instead.');
13 |
--------------------------------------------------------------------------------
/fixtures/packaging/brunch/dev/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "private": true,
3 | "name": "brunch-dev-fixture",
4 | "devDependencies": {
5 | "brunch": "^2.9.1",
6 | "javascript-brunch": "^2.0.0"
7 | },
8 | "scripts": {
9 | "build": "rm -rf public && brunch build",
10 | "prebuild": "cp -r ../../../../build/oss-experimental/* ./node_modules/"
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/deploy.chrome.html:
--------------------------------------------------------------------------------
1 |
2 | - download extension
3 | - Double-click to extract
4 | - Navigate to
chrome://extensions/
5 | - Enable "Developer mode"
6 | - Click "LOAD UNPACKED"
7 | - Select extracted extension folder (
ReactDevTools)
8 |
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/deploy.firefox.html:
--------------------------------------------------------------------------------
1 |
2 | - download extension
3 | - Extract/unzip
4 | - Visit
about:debugging
5 | - Click "Load Temporary Add-on"
6 | - Select the
manifest.json file inside of the extracted extension folder (ReactDevTools)
7 |
--------------------------------------------------------------------------------
/packages/react-dom/unstable_server-external-runtime.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from 'react-dom-bindings/src/server/ReactDOMServerExternalRuntime';
11 |
--------------------------------------------------------------------------------
/packages/react/src/ReactSharedSubsetFB.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './ReactSharedSubset';
11 | export {jsx, jsxs, jsxDEV} from './jsx/ReactJSX';
12 |
--------------------------------------------------------------------------------
/packages/use-sync-external-store/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | 'use strict';
11 |
12 | export {useSyncExternalStore} from './src/useSyncExternalStore';
13 |
--------------------------------------------------------------------------------
/fixtures/packaging/brunch/prod/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "private": true,
3 | "name": "brunch-prod-fixture",
4 | "devDependencies": {
5 | "brunch": "^2.9.1",
6 | "javascript-brunch": "^2.0.0"
7 | },
8 | "scripts": {
9 | "build": "rm -rf public && brunch build -p",
10 | "prebuild": "cp -r ../../../../build/oss-experimental/* ./node_modules/"
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/popups/restricted.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
10 |
11 | This is a restricted browser page.
12 |
13 | React devtools cannot access this page.
14 |
15 |
--------------------------------------------------------------------------------
/packages/react-devtools-timeline/src/view-base/resizable/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './ResizableView';
11 | export * from './ResizeBarView';
12 |
--------------------------------------------------------------------------------
/packages/react-dom/src/server/react-dom-server.edge.stable.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export {renderToReadableStream, version} from './ReactDOMFizzServerEdge.js';
11 |
--------------------------------------------------------------------------------
/packages/react-dom/src/server/react-dom-server.node.stable.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export {renderToPipeableStream, version} from './ReactDOMFizzServerNode.js';
11 |
--------------------------------------------------------------------------------
/packages/react-dom/static.node.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export {
11 | prerenderToNodeStream,
12 | version,
13 | } from './src/server/react-dom-server.node';
14 |
--------------------------------------------------------------------------------
/packages/react-native-renderer/src/__mocks__/react-native/Libraries/ReactPrivate/Platform.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | */
7 | 'use strict';
8 |
9 | module.exports = {
10 | OS: 'ios',
11 | };
12 |
--------------------------------------------------------------------------------
/packages/react-server-dom-esm/esm/react-server-dom-esm-node-loader.production.min.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from '../src/ReactFlightESMNodeLoader.js';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/npm/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | 'use strict';
11 |
12 | throw new Error('Use react-server-dom-webpack/client instead.');
13 |
--------------------------------------------------------------------------------
/scripts/rollup/wrappers/registerInternalModuleEnd.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | /* global __REACT_DEVTOOLS_GLOBAL_HOOK__ */
4 | if (
5 | typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ !== 'undefined' &&
6 | typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop ===
7 | 'function'
8 | ) {
9 | __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(new Error());
10 | }
11 |
--------------------------------------------------------------------------------
/.editorconfig:
--------------------------------------------------------------------------------
1 | # https://editorconfig.org
2 | root = true
3 |
4 | [*]
5 | charset = utf-8
6 | end_of_line = lf
7 | indent_size = 2
8 | indent_style = space
9 | insert_final_newline = true
10 | max_line_length = 80
11 | trim_trailing_whitespace = true
12 |
13 | [*.md]
14 | max_line_length = 0
15 | trim_trailing_whitespace = false
16 |
17 | [COMMIT_EDITMSG]
18 | max_line_length = 0
19 |
--------------------------------------------------------------------------------
/packages/react-native-renderer/src/__mocks__/react-native/Libraries/ReactPrivate/legacySendAccessibilityEvent.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | */
7 |
8 | 'use strict';
9 |
10 | module.exports = jest.fn();
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/npm/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | 'use strict';
11 |
12 | throw new Error('Use react-server-dom-turbopack/client instead.');
13 |
--------------------------------------------------------------------------------
/scripts/rollup/wrappers/registerInternalModuleBegin.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | /* global __REACT_DEVTOOLS_GLOBAL_HOOK__ */
4 | if (
5 | typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ !== 'undefined' &&
6 | typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart ===
7 | 'function'
8 | ) {
9 | __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(new Error());
10 | }
11 |
--------------------------------------------------------------------------------
/fixtures/packaging/systemjs-builder/dev/build.js:
--------------------------------------------------------------------------------
1 | var Builder = require('systemjs-builder');
2 |
3 | var builder = new Builder('/', './config.js');
4 | builder
5 | .buildStatic('./input.js', './output.js')
6 | .then(function () {
7 | console.log('Build complete');
8 | })
9 | .catch(function (err) {
10 | console.log('Build error');
11 | console.log(err);
12 | });
13 |
--------------------------------------------------------------------------------
/fixtures/packaging/systemjs-builder/prod/build.js:
--------------------------------------------------------------------------------
1 | var Builder = require('systemjs-builder');
2 |
3 | var builder = new Builder('/', './config.js');
4 | builder
5 | .buildStatic('./input.js', './output.js')
6 | .then(function () {
7 | console.log('Build complete');
8 | })
9 | .catch(function (err) {
10 | console.log('Build error');
11 | console.log(err);
12 | });
13 |
--------------------------------------------------------------------------------
/fixtures/ssr2/src/NavBar.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | */
8 |
9 | export default function NavBar() {
10 | return (
11 |
14 | );
15 | }
16 |
--------------------------------------------------------------------------------
/packages/react-devtools-timeline/README.md:
--------------------------------------------------------------------------------
1 | # React Concurrent Mode Profiler
2 |
3 | This package contains the new/experimental "timeline" for React 18. This profiler exists as its own project because it was initially deployed as a standalone app. It has since been moved into the DevTools Profiler under the "Scheduling" tab. This package will likely eventually be moved into `react-devtools-shared`.
--------------------------------------------------------------------------------
/packages/react-dom/src/server/react-dom-server.browser.stable.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export {renderToReadableStream, version} from './ReactDOMFizzServerBrowser.js';
11 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/esm/react-server-dom-webpack-node-loader.production.min.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from '../src/ReactFlightWebpackNodeLoader.js';
11 |
--------------------------------------------------------------------------------
/fixtures/dom/src/components/App.js:
--------------------------------------------------------------------------------
1 | import Header from './Header';
2 | import Fixtures from './fixtures';
3 | import '../style.css';
4 |
5 | const React = window.React;
6 |
7 | class App extends React.Component {
8 | render() {
9 | return (
10 |
11 |
12 |
13 |
14 | );
15 | }
16 | }
17 |
18 | export default App;
19 |
--------------------------------------------------------------------------------
/fixtures/nesting/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | React App
7 |
8 |
9 |
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/fixtures/packaging/systemjs-builder/dev/config.js:
--------------------------------------------------------------------------------
1 | System.config({
2 | paths: {
3 | react: '../../../../build/oss-experimental/react/umd/react.development.js',
4 | 'react-dom':
5 | '../../../../build/oss-experimental/react-dom/umd/react-dom.development.js',
6 | schedule:
7 | '../../../../build/oss-experimental/scheduler/umd/schedule.development',
8 | },
9 | });
10 |
--------------------------------------------------------------------------------
/packages/react-reconciler/src/ReactRootTags.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export type RootTag = 0 | 1;
11 |
12 | export const LegacyRoot = 0;
13 | export const ConcurrentRoot = 1;
14 |
--------------------------------------------------------------------------------
/packages/react-server/src/forks/ReactServerStreamConfig.dom-legacy.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from 'react-dom-bindings/src/server/ReactDOMLegacyServerStreamConfig';
11 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/ErrorBoundary/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | import ErrorBoundary from './ErrorBoundary';
11 |
12 | export default ErrorBoundary;
13 |
--------------------------------------------------------------------------------
/packages/react-native-renderer/src/__tests__/__snapshots__/ReactNativeEvents-test.internal.js.snap:
--------------------------------------------------------------------------------
1 | // Jest Snapshot v1, https://goo.gl/fbAQLP
2 |
3 | exports[`fails if unknown/unsupported event types are dispatched 1`] = `
4 | " {}
5 | View null"
6 | `;
7 |
8 | exports[`handles events 1`] = `
9 | " {}
10 | View {"foo":"outer"}
11 | View {"foo":"inner"}"
12 | `;
13 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/esm/react-server-dom-turbopack-node-loader.production.min.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from '../src/ReactFlightTurbopackNodeLoader.js';
11 |
--------------------------------------------------------------------------------
/scripts/circleci/check_license.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -e
4 |
5 | # Make sure we don't introduce accidental references to PATENTS.
6 | EXPECTED='scripts/circleci/check_license.sh'
7 | ACTUAL=$(git grep -l PATENTS)
8 |
9 | if [ "$EXPECTED" != "$ACTUAL" ]; then
10 | echo "PATENTS crept into some new files?"
11 | diff -u <(echo "$EXPECTED") <(echo "$ACTUAL") || true
12 | exit 1
13 | fi
14 |
--------------------------------------------------------------------------------
/fixtures/fizz/src/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | */
8 |
9 | import {hydrateRoot} from 'react-dom/client';
10 | import App from './App';
11 |
12 | hydrateRoot(document, );
13 |
--------------------------------------------------------------------------------
/fixtures/flight/src/ShowMore.js:
--------------------------------------------------------------------------------
1 | 'use client';
2 |
3 | import * as React from 'react';
4 |
5 | import Container from './Container.js';
6 |
7 | export default function ShowMore({children}) {
8 | const [show, setShow] = React.useState(false);
9 | if (!show) {
10 | return ;
11 | }
12 | return {children};
13 | }
14 |
--------------------------------------------------------------------------------
/fixtures/nesting/src/shared/useTime.js:
--------------------------------------------------------------------------------
1 | import {useState, useEffect} from 'react';
2 |
3 | export default function useTimer() {
4 | const [value, setValue] = useState(() => new Date());
5 | useEffect(() => {
6 | const id = setInterval(() => {
7 | setValue(new Date());
8 | }, 1000);
9 | return () => clearInterval(id);
10 | }, []);
11 | return value.toLocaleTimeString();
12 | }
13 |
--------------------------------------------------------------------------------
/fixtures/ssr2/src/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | */
8 |
9 | import {hydrateRoot} from 'react-dom/client';
10 | import App from './App';
11 |
12 | hydrateRoot(document, );
13 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/Components/ElementBadges.css:
--------------------------------------------------------------------------------
1 | .Root {
2 | display: inline-flex;
3 | align-items: center;
4 | }
5 |
6 | .Root *:not(:first-child) {
7 | margin-left: 0.25rem;
8 | }
9 |
10 | .ExtraLabel {
11 | font-family: var(--font-family-monospace);
12 | font-size: var(--font-size-monospace-small);
13 | color: var(--color-component-badge-count);
14 | }
15 |
--------------------------------------------------------------------------------
/packages/react-devtools-shell/src/app/styles.css:
--------------------------------------------------------------------------------
1 | body {
2 | /* GitHub.com frontend fonts */
3 | font-family: -apple-system, BlinkMacSystemFont, Segoe UI, Helvetica, Arial,
4 | sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol;
5 | font-size: 14px;
6 | line-height: 1.5;
7 | }
8 |
9 | h1 {
10 | font-size: 1.5rem;
11 | font-weight: bold;
12 | margin-bottom: 0.5rem;
13 | }
14 |
--------------------------------------------------------------------------------
/packages/react-dom/src/server/react-dom-server.edge.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './ReactDOMFizzServerEdge.js';
11 | export {prerender} from './ReactDOMFizzStaticEdge.js';
12 |
--------------------------------------------------------------------------------
/packages/use-sync-external-store/shim/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | 'use strict';
11 |
12 | export {useSyncExternalStore} from 'use-sync-external-store/src/useSyncExternalStoreShim';
13 |
--------------------------------------------------------------------------------
/fixtures/attribute-behavior/public/manifest.json:
--------------------------------------------------------------------------------
1 | {
2 | "short_name": "React App",
3 | "name": "Create React App Sample",
4 | "icons": [
5 | {
6 | "src": "favicon.ico",
7 | "sizes": "192x192",
8 | "type": "image/png"
9 | }
10 | ],
11 | "start_url": "./index.html",
12 | "display": "standalone",
13 | "theme_color": "#000000",
14 | "background_color": "#ffffff"
15 | }
16 |
--------------------------------------------------------------------------------
/fixtures/devtools/scheduling-profiler/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Scheduling Profiler Fixture
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/fixtures/flight-esm/.gitignore:
--------------------------------------------------------------------------------
1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
2 |
3 | # dependencies
4 | /node_modules
5 | /.pnp
6 | .pnp.js
7 |
8 | # testing
9 | /coverage
10 |
11 | # misc
12 | .DS_Store
13 | .env.local
14 | .env.development.local
15 | .env.test.local
16 | .env.production.local
17 |
18 | npm-debug.log*
19 | yarn-debug.log*
20 | yarn-error.log*
21 |
--------------------------------------------------------------------------------
/fixtures/packaging/systemjs-builder/prod/config.js:
--------------------------------------------------------------------------------
1 | System.config({
2 | paths: {
3 | react:
4 | '../../../../build/oss-experimental/react/umd/react.production.min.js',
5 | 'react-dom':
6 | '../../../../build/oss-experimental/react-dom/umd/react-dom.production.min.js',
7 | schedule:
8 | '../../../../build/oss-experimental/scheduler/umd/schedule.development',
9 | },
10 | });
11 |
--------------------------------------------------------------------------------
/packages/react-devtools-timeline/src/import-worker/importFile.worker.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | */
7 |
8 | import * as importFileModule from './importFile';
9 |
10 | export const importFile = importFileModule.importFile;
11 |
--------------------------------------------------------------------------------
/packages/react-dom/src/server/react-dom-server.browser.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './ReactDOMFizzServerBrowser.js';
11 | export {prerender} from './ReactDOMFizzStaticBrowser.js';
12 |
--------------------------------------------------------------------------------
/packages/react-native-renderer/src/__mocks__/react-native/Libraries/ReactPrivate/ExceptionsManager.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | */
7 |
8 | 'use strict';
9 |
10 | module.exports = {
11 | handleException: jest.fn(),
12 | };
13 |
--------------------------------------------------------------------------------
/packages/scheduler/README.md:
--------------------------------------------------------------------------------
1 | # `scheduler`
2 |
3 | This is a package for cooperative scheduling in a browser environment. It is currently used internally by React, but we plan to make it more generic.
4 |
5 | The public API for this package is not yet finalized.
6 |
7 | ### Thanks
8 |
9 | The React team thanks [Anton Podviaznikov](https://podviaznikov.com/) for donating the `scheduler` package name.
10 |
--------------------------------------------------------------------------------
/packages/shared/hasOwnProperty.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | // $FlowFixMe[method-unbinding]
11 | const hasOwnProperty = Object.prototype.hasOwnProperty;
12 |
13 | export default hasOwnProperty;
14 |
--------------------------------------------------------------------------------
/scripts/eslint-rules/README.md:
--------------------------------------------------------------------------------
1 | # Custom ESLint Rules
2 |
3 | This is a dummy npm package that allows us to treat it as an `eslint-plugin`. It's not actually published, nor are the rules here useful for users of React. If you want to lint your React code, try .
4 |
5 | **If you modify this rule, you must re-run `npm install ./eslint-rules` for it to take effect.**
6 |
--------------------------------------------------------------------------------
/fixtures/ssr/src/components/Page2.js:
--------------------------------------------------------------------------------
1 | import React, {useContext} from 'react';
2 |
3 | import Theme from './Theme';
4 | import Suspend from './Suspend';
5 |
6 | import './Page.css';
7 |
8 | export default function Page2() {
9 | let theme = useContext(Theme);
10 | return (
11 |
12 | Content of a different page
13 |
14 | );
15 | }
16 |
--------------------------------------------------------------------------------
/packages/react-debug-tools/src/ReactDebugTools.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | import {inspectHooks, inspectHooksOfFiber} from './ReactDebugHooks';
11 |
12 | export {inspectHooks, inspectHooksOfFiber};
13 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/Components/IndexableElementBadges.css:
--------------------------------------------------------------------------------
1 | .Root {
2 | display: inline-flex;
3 | align-items: center;
4 | }
5 |
6 | .Root *:not(:first-child) {
7 | margin-left: 0.25rem;
8 | }
9 |
10 | .ExtraLabel {
11 | font-family: var(--font-family-monospace);
12 | font-size: var(--font-size-monospace-small);
13 | color: var(--color-component-badge-count);
14 | }
15 |
--------------------------------------------------------------------------------
/packages/react-devtools-shell/src/app/InspectableElements/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | import InspectableElements from './InspectableElements';
11 |
12 | export default InspectableElements;
13 |
--------------------------------------------------------------------------------
/packages/react-devtools-timeline/src/view-base/vertical-scroll-overflow/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './VerticalScrollBarView';
11 | export * from './VerticalScrollOverflowView';
12 |
--------------------------------------------------------------------------------
/packages/react-dom/src/server/react-dom-server.node.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export * from './ReactDOMFizzServerNode.js';
11 | export {prerenderToNodeStream} from './ReactDOMFizzStaticNode.js';
12 |
--------------------------------------------------------------------------------
/packages/use-sync-external-store/shim/index.native.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | 'use strict';
11 |
12 | export {useSyncExternalStore} from 'use-sync-external-store/src/useSyncExternalStoreShim';
13 |
--------------------------------------------------------------------------------
/packages/use-sync-external-store/src/isServerEnvironment.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | import {canUseDOM} from 'shared/ExecutionEnvironment';
11 |
12 | export const isServerEnvironment = !canUseDOM;
13 |
--------------------------------------------------------------------------------
/packages/react-devtools-extensions/popups/shared.css:
--------------------------------------------------------------------------------
1 | html, body {
2 | font-size: 14px;
3 | }
4 |
5 | body {
6 | margin: 8px;
7 | }
8 |
9 | @media (prefers-color-scheme: dark) {
10 | :root {
11 | color-scheme: dark;
12 | }
13 |
14 | @supports (-moz-appearance:none) {
15 | :root {
16 | background: black;
17 | }
18 |
19 | body {
20 | color: white;
21 | }
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/Profiler/constants.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export const barWidthThreshold = 2;
11 | export const maxBarWidth = 30;
12 | export const minBarWidth = 5;
13 |
--------------------------------------------------------------------------------
/packages/react-native-renderer/src/__mocks__/react-native/Libraries/ReactPrivate/ReactFiberErrorDialog.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow strict
8 | */
9 |
10 | module.exports = {
11 | showErrorDialog: jest.fn(),
12 | };
13 |
--------------------------------------------------------------------------------
/fixtures/concurrent/time-slicing/.gitignore:
--------------------------------------------------------------------------------
1 | # See https://help.github.com/ignore-files/ for more about ignoring files.
2 |
3 | # dependencies
4 | /node_modules
5 |
6 | # testing
7 | /coverage
8 |
9 | # production
10 | /build
11 |
12 | # misc
13 | .DS_Store
14 | .env.local
15 | .env.development.local
16 | .env.test.local
17 | .env.production.local
18 |
19 | npm-debug.log*
20 | yarn-debug.log*
21 | yarn-error.log*
22 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/Components/SelectedTreeHighlight.css:
--------------------------------------------------------------------------------
1 | .Active,
2 | .Inactive {
3 | position: absolute;
4 | left: 0;
5 | width: 100%;
6 | z-index: 0;
7 | pointer-events: none;
8 | }
9 |
10 | .Active {
11 | background-color: var(--color-selected-tree-highlight-active);
12 | }
13 |
14 | .Inactive {
15 | background-color: var(--color-selected-tree-highlight-inactive);
16 | }
17 |
--------------------------------------------------------------------------------
/packages/react-devtools-shell/src/app/ToDoList/ListItem.css:
--------------------------------------------------------------------------------
1 | .ListItem {
2 | list-style-type: none;
3 | }
4 |
5 | .Input {
6 | cursor: pointer;
7 | }
8 |
9 | .Label {
10 | cursor: pointer;
11 | padding: 0.25rem;
12 | color: #555;
13 | }
14 | .Label:hover {
15 | color: #000;
16 | }
17 |
18 | .IconButton {
19 | padding: 0.25rem;
20 | border: none;
21 | background: none;
22 | cursor: pointer;
23 | }
24 |
--------------------------------------------------------------------------------
/SECURITY.md:
--------------------------------------------------------------------------------
1 | # Reporting Security Issues
2 |
3 | If you believe you have found a security vulnerability in React, we encourage you to let us know right away. We will investigate all legitimate reports and do our best to quickly fix the problem.
4 |
5 | Please refer to the following page for our responsible disclosure policy, reward guidelines, and those things that should not be reported:
6 |
7 | https://www.facebook.com/whitehat
8 |
--------------------------------------------------------------------------------
/fixtures/packaging/webpack-alias/dev/config.js:
--------------------------------------------------------------------------------
1 | var path = require('path');
2 |
3 | module.exports = {
4 | entry: './input',
5 | output: {
6 | filename: 'output.js',
7 | },
8 | resolve: {
9 | root: path.resolve('../../../../build/oss-experimental'),
10 | alias: {
11 | react: 'react/umd/react.development',
12 | 'react-dom': 'react-dom/umd/react-dom.development',
13 | },
14 | },
15 | };
16 |
--------------------------------------------------------------------------------
/packages/react-dom-bindings/src/client/DOMNamespaces.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export const MATH_NAMESPACE = 'http://www.w3.org/1998/Math/MathML';
11 | export const SVG_NAMESPACE = 'http://www.w3.org/2000/svg';
12 |
--------------------------------------------------------------------------------
/packages/use-sync-external-store/with-selector.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | 'use strict';
11 |
12 | export {useSyncExternalStoreWithSelector} from 'use-sync-external-store/src/useSyncExternalStoreWithSelector';
13 |
--------------------------------------------------------------------------------
/fixtures/concurrent/time-slicing/public/manifest.json:
--------------------------------------------------------------------------------
1 | {
2 | "short_name": "React App",
3 | "name": "Create React App Sample",
4 | "icons": [
5 | {
6 | "src": "favicon.ico",
7 | "sizes": "64x64 32x32 24x24 16x16",
8 | "type": "image/x-icon"
9 | }
10 | ],
11 | "start_url": "./index.html",
12 | "display": "standalone",
13 | "theme_color": "#000000",
14 | "background_color": "#ffffff"
15 | }
16 |
--------------------------------------------------------------------------------
/fixtures/dom/README.md:
--------------------------------------------------------------------------------
1 | # DOM Fixtures
2 |
3 | A set of DOM test cases for quickly identifying browser issues.
4 |
5 | ## Setup
6 |
7 | To reference a local build of React, first run `yarn build` at the root
8 | of the React project. Then:
9 |
10 | ```
11 | cd fixtures/dom
12 | yarn
13 | yarn start
14 | ```
15 |
16 | The `start` command runs a script that copies over the local build of react into
17 | the public directory.
18 |
--------------------------------------------------------------------------------
/fixtures/nesting/src/modern/index.js:
--------------------------------------------------------------------------------
1 | import React from 'react';
2 | import {StrictMode} from 'react';
3 | import ReactDOM from 'react-dom';
4 | import {Provider} from 'react-redux';
5 | import App from './App';
6 | import {store} from '../store';
7 |
8 | ReactDOM.render(
9 |
10 |
11 |
12 |
13 | ,
14 | document.getElementById('root')
15 | );
16 |
--------------------------------------------------------------------------------
/fixtures/packaging/webpack-alias/prod/config.js:
--------------------------------------------------------------------------------
1 | var path = require('path');
2 |
3 | module.exports = {
4 | entry: './input',
5 | output: {
6 | filename: 'output.js',
7 | },
8 | resolve: {
9 | root: path.resolve('../../../../build/oss-experimental'),
10 | alias: {
11 | react: 'react/umd/react.production.min',
12 | 'react-dom': 'react-dom/umd/react-dom.production.min',
13 | },
14 | },
15 | };
16 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/Components/Badge.css:
--------------------------------------------------------------------------------
1 | .Badge {
2 | display: inline-block;
3 | background-color: var(--color-component-badge-background);
4 | color: var(--color-text);
5 | padding: 0.125rem 0.25rem;
6 | line-height: normal;
7 | border-radius: 0.125rem;
8 | margin-right: 0.25rem;
9 | font-family: var(--font-family-monospace);
10 | font-size: var(--font-size-monospace-small);
11 | }
12 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/Profiler/NoCommitData.css:
--------------------------------------------------------------------------------
1 | .NoCommitData {
2 | width: 100%;
3 | height: 100%;
4 | display: flex;
5 | flex-direction: column;
6 | align-items: center;
7 | justify-content: center;
8 | }
9 |
10 | .Header {
11 | font-size: var(--font-size-sans-large);
12 | margin-bottom: 0.5rem;
13 | }
14 |
15 | .FilterMessage {
16 | display: flex;
17 | align-items: center;
18 | }
19 |
--------------------------------------------------------------------------------
/scripts/rollup/shims/facebook-www/renderSubtreeIntoContainer_DO_NOT_USE.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | */
7 |
8 | 'use strict';
9 |
10 | const ReactDOM = require('ReactDOM');
11 |
12 | module.exports = ReactDOM.unstable_renderSubtreeIntoContainer;
13 |
--------------------------------------------------------------------------------
/.codesandbox/ci.json:
--------------------------------------------------------------------------------
1 | {
2 | "packages": ["packages/react", "packages/react-dom", "packages/scheduler"],
3 | "buildCommand": "download-build-in-codesandbox-ci",
4 | "node": "18",
5 | "publishDirectory": {
6 | "react": "build/oss-experimental/react",
7 | "react-dom": "build/oss-experimental/react-dom",
8 | "scheduler": "build/oss-experimental/scheduler"
9 | },
10 | "sandboxes": ["new"],
11 | "silent": true
12 | }
13 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/hooks/__tests__/__source__/InlineRequire.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export function Component() {
11 | const [count] = require('react').useState(0);
12 |
13 | return count;
14 | }
15 |
--------------------------------------------------------------------------------
/packages/react-dom-bindings/src/server/fizz-instruction-set/ReactDOMFizzInlineCompleteBoundaryWithStyles.js:
--------------------------------------------------------------------------------
1 | import {completeBoundaryWithStyles} from './ReactDOMFizzInstructionSetInlineSource';
2 |
3 | // This is a string so Closure's advanced compilation mode doesn't mangle it.
4 | // eslint-disable-next-line dot-notation
5 | window['$RM'] = new Map();
6 | // eslint-disable-next-line dot-notation
7 | window['$RR'] = completeBoundaryWithStyles;
8 |
--------------------------------------------------------------------------------
/packages/use-sync-external-store/shim/with-selector/index.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | 'use strict';
11 |
12 | export {useSyncExternalStoreWithSelector} from 'use-sync-external-store/src/useSyncExternalStoreWithSelector';
13 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/hooks/__tests__/__source__/README.md:
--------------------------------------------------------------------------------
1 | The JavaScript files and source maps in this directory are used to test DevTools hook name parsing code. The files here use source maps in different formats to mirror real world applications. The source for the files is located in the parent `__tests__` folder. To regenerate these compiled files, run `yarn update-mock-source-maps` in the `react-devtools-extensions` directory.
2 |
--------------------------------------------------------------------------------
/packages/react-native-renderer/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "react-native-renderer",
3 | "version": "16.0.0",
4 | "private": true,
5 | "repository": {
6 | "type" : "git",
7 | "url" : "https://github.com/facebook/react.git",
8 | "directory": "packages/react-native-renderer"
9 | },
10 | "dependencies": {
11 | "scheduler": "^0.23.0"
12 | },
13 | "peerDependencies": {
14 | "react": "^18.0.0"
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/src/ReactFlightClientConfigBundlerTurbopackBrowser.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export function loadChunk(filename: string): Promise {
11 | return __turbopack_load__(filename);
12 | }
13 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/src/ReactFlightClientConfigBundlerTurbopackServer.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export function loadChunk(filename: string): Promise {
11 | return __turbopack_load__(filename);
12 | }
13 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/Components/NativeStyleEditor/AutoSizeInput.css:
--------------------------------------------------------------------------------
1 | .Input {
2 | min-width: 0.5rem;
3 | flex: 1 1 auto;
4 | border: none;
5 | background: transparent;
6 | outline: none;
7 | padding: 0;
8 | border: none;
9 | font-family: var(--font-family-monospace);
10 | font-size: var(--font-size-monospace-normal);
11 | }
12 |
13 | .Input:focus {
14 | border-color: var(--color-border);
15 | }
16 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/root.css:
--------------------------------------------------------------------------------
1 | :root {
2 | /* Font smoothing */
3 | --font-smoothing: auto;
4 |
5 | /* GitHub.com system fonts */
6 | --font-family-monospace: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo,
7 | Courier, monospace;
8 | --font-family-sans: -apple-system, BlinkMacSystemFont, Segoe UI, Helvetica,
9 | Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol;
10 | }
11 |
--------------------------------------------------------------------------------
/packages/react-reconciler/src/__mocks__/scheduler/tracing.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | // This placeholder is to support a legacy/regression test in ReactFresh-test.
11 | // Without this mock, jest.mock('scheduler/tracing') throws.
12 |
--------------------------------------------------------------------------------
/fixtures/dom/src/components/Fixture.js:
--------------------------------------------------------------------------------
1 | import PropTypes from 'prop-types';
2 | const React = window.React;
3 |
4 | const propTypes = {
5 | children: PropTypes.node.isRequired,
6 | };
7 |
8 | class Fixture extends React.Component {
9 | render() {
10 | const {children} = this.props;
11 |
12 | return {children}
;
13 | }
14 | }
15 |
16 | Fixture.propTypes = propTypes;
17 |
18 | export default Fixture;
19 |
--------------------------------------------------------------------------------
/packages/eslint-plugin-react-hooks/npm/index.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | // TODO: this doesn't make sense for an ESLint rule.
4 | // We need to fix our build process to not create bundles for "raw" packages like this.
5 | if (process.env.NODE_ENV === 'production') {
6 | module.exports = require('./cjs/eslint-plugin-react-hooks.production.min.js');
7 | } else {
8 | module.exports = require('./cjs/eslint-plugin-react-hooks.development.js');
9 | }
10 |
--------------------------------------------------------------------------------
/packages/react-native-renderer/src/__mocks__/react-native/Libraries/ReactPrivate/RCTEventEmitter.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | */
7 |
8 | 'use strict';
9 |
10 | const RCTEventEmitter = {
11 | register: jest.fn(),
12 | };
13 |
14 | module.exports = RCTEventEmitter;
15 |
--------------------------------------------------------------------------------
/scripts/devtools/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "react-devtools-release-script",
3 | "version": "0.0.0",
4 | "private": true,
5 | "scripts": {},
6 | "license": "MIT",
7 | "dependencies": {
8 | "chalk": "^2.1.0",
9 | "child-process-promise": "^2.2.1",
10 | "fs-extra": "^4.0.2",
11 | "inquirer": "^8.1.2",
12 | "progress-estimator": "^0.2.1",
13 | "prompt-promise": "^1.0.3",
14 | "semver": "^5.4.1"
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/fixtures/flight/.gitignore:
--------------------------------------------------------------------------------
1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
2 |
3 | # dependencies
4 | /node_modules
5 | /.pnp
6 | .pnp.js
7 |
8 | # testing
9 | /coverage
10 |
11 | # production
12 | /build
13 | .eslintcache
14 |
15 | # misc
16 | .DS_Store
17 | .env.local
18 | .env.development.local
19 | .env.test.local
20 | .env.production.local
21 |
22 | npm-debug.log*
23 | yarn-debug.log*
24 | yarn-error.log*
25 |
--------------------------------------------------------------------------------
/fixtures/flight/src/ErrorBoundary.js:
--------------------------------------------------------------------------------
1 | 'use client';
2 |
3 | import * as React from 'react';
4 |
5 | export default class ErrorBoundary extends React.Component {
6 | state = {error: null};
7 | static getDerivedStateFromError(error) {
8 | return {error};
9 | }
10 | render() {
11 | if (this.state.error) {
12 | return Caught an error: {this.state.error.message}
;
13 | }
14 | return this.props.children;
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/fixtures/nesting/src/store.js:
--------------------------------------------------------------------------------
1 | import {createStore} from 'redux';
2 |
3 | function reducer(state = 0, action) {
4 | switch (action.type) {
5 | case 'increment':
6 | return state + 1;
7 | default:
8 | return state;
9 | }
10 | }
11 |
12 | // Because this file is declared above both Modern and Legacy folders,
13 | // we can import this from either folder without duplicating the object.
14 | export const store = createStore(reducer);
15 |
--------------------------------------------------------------------------------
/packages/react-dom/src/server/react-dom-server.bun.stable.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export {
11 | renderToReadableStream,
12 | renderToNodeStream,
13 | renderToStaticNodeStream,
14 | version,
15 | } from './ReactDOMFizzServerBun.js';
16 |
--------------------------------------------------------------------------------
/packages/react-native-renderer/src/__mocks__/react-native/Libraries/ReactPrivate/BatchedBridge.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | */
7 |
8 | 'use strict';
9 |
10 | const BatchedBridge = {
11 | registerCallableModule: jest.fn(),
12 | };
13 |
14 | module.exports = BatchedBridge;
15 |
--------------------------------------------------------------------------------
/packages/react-native-renderer/src/__mocks__/react-native/Libraries/ReactPrivate/flattenStyle.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | */
7 |
8 | 'use strict';
9 |
10 | // TODO: Move flattenStyle into react
11 |
12 | function flattenStyle() {}
13 |
14 | module.exports = flattenStyle;
15 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/src/ReactFlightClientConfigBundlerWebpackServer.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export function loadChunk(chunkId: string, filename: string): Promise {
11 | return __webpack_chunk_load__(chunkId);
12 | }
13 |
--------------------------------------------------------------------------------
/packages/react/src/ReactServerContextRegistry.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | import type {ReactServerContext} from 'shared/ReactTypes';
11 |
12 | export const ContextRegistry: {
13 | [globalName: string]: ReactServerContext,
14 | } = {};
15 |
--------------------------------------------------------------------------------
/packages/react-devtools-shared/src/devtools/views/Components/NewArrayValue.css:
--------------------------------------------------------------------------------
1 | .NewArrayValue {
2 | white-space: nowrap;
3 | display: flex;
4 | align-items: center;
5 | }
6 |
7 | .EditableName {
8 | margin-left: 1rem;
9 | }
10 |
11 | .Invalid {
12 | background-color: var(--color-background-invalid);
13 | color: var(--color-text-invalid) !important;
14 | }
15 |
16 | .Invalid:focus {
17 | background-color: var(--color-button-background-focus);
18 | }
--------------------------------------------------------------------------------
/packages/react-devtools-timeline/src/import-worker/InvalidProfileError.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | /**
11 | * An error thrown when an invalid profile could not be processed.
12 | */
13 | export default class InvalidProfileError extends Error {}
14 |
--------------------------------------------------------------------------------
/scripts/jest/config.source.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | const baseConfig = require('./config.base');
4 |
5 | module.exports = Object.assign({}, baseConfig, {
6 | modulePathIgnorePatterns: [
7 | ...baseConfig.modulePathIgnorePatterns,
8 | 'packages/react-devtools-extensions',
9 | 'packages/react-devtools-shared',
10 | ],
11 | setupFiles: [
12 | ...baseConfig.setupFiles,
13 | require.resolve('./setupHostConfigs.js'),
14 | ],
15 | });
16 |
--------------------------------------------------------------------------------
/scripts/release/prepare-release-from-npm-commands/get-latest-next-version.js:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env node
2 |
3 | 'use strict';
4 |
5 | const {execRead, logPromise} = require('../utils');
6 |
7 | const run = async () => {
8 | const version = await execRead('npm info react@canary version');
9 |
10 | return version;
11 | };
12 |
13 | module.exports = async params => {
14 | return logPromise(run(params), 'Determining latest "canary" release version');
15 | };
16 |
--------------------------------------------------------------------------------
/fixtures/packaging/rjs/dev/config.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | baseUrl: '.',
3 | name: 'input',
4 | out: 'output.js',
5 | optimize: 'none',
6 | paths: {
7 | react: '../../../../build/oss-experimental/react/umd/react.development',
8 | 'react-dom':
9 | '../../../../build/oss-experimental/react-dom/umd/react-dom.development',
10 | schedule:
11 | '../../../../build/oss-experimental/scheduler/umd/schedule.development',
12 | },
13 | };
14 |
--------------------------------------------------------------------------------
/packages/react-server-dom-esm/server.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | throw new Error(
11 | 'The React Server cannot be used outside a react-server environment. ' +
12 | 'You must configure Node.js using the `--conditions react-server` flag.',
13 | );
14 |
--------------------------------------------------------------------------------
/packages/react-server-dom-fb/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "react-server-dom-fb",
3 | "version": "0.1.0",
4 | "private": true,
5 | "repository": {
6 | "type" : "git",
7 | "url" : "https://github.com/facebook/react.git",
8 | "directory": "packages/react-server-dom-fb"
9 | },
10 | "dependencies": {
11 | "scheduler": "^0.23.0"
12 | },
13 | "peerDependencies": {
14 | "react": "^18.0.0",
15 | "react-dom": "^18.0.0"
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/packages/shared/ReactSharedInternals.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | import * as React from 'react';
11 |
12 | const ReactSharedInternals =
13 | React.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
14 |
15 | export default ReactSharedInternals;
16 |
--------------------------------------------------------------------------------
/fixtures/packaging/browserify/prod/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "private": true,
3 | "name": "browserify-prod-fixture",
4 | "dependencies": {
5 | "browserify": "^13.3.0"
6 | },
7 | "scripts": {
8 | "build": "rm -f output.js && browserify ./input.js -g [envify --NODE_ENV 'production'] -o output.js",
9 | "prebuild": "cp -r ../../../../build/oss-experimental/* ./node_modules/"
10 | },
11 | "devDependencies": {
12 | "envify": "^4.0.0"
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/fixtures/packaging/rjs/prod/config.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | baseUrl: '.',
3 | name: 'input',
4 | out: 'output.js',
5 | optimize: 'none',
6 | paths: {
7 | react: '../../../../build/oss-experimental/react/umd/react.production.min',
8 | 'react-dom':
9 | '../../../../build/oss-experimental/react-dom/umd/react-dom.production.min',
10 | schedule:
11 | '../../../../build/oss-experimental/scheduler/umd/schedule.development',
12 | },
13 | };
14 |
--------------------------------------------------------------------------------
/packages/react-dom-bindings/src/events/PluginModuleType.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export type AnyNativeEvent = Event | KeyboardEvent | MouseEvent | TouchEvent;
11 |
12 | export type PluginName = string;
13 |
14 | export type EventSystemFlags = number;
15 |
--------------------------------------------------------------------------------
/packages/react-server-dom-turbopack/server.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | throw new Error(
11 | 'The React Server cannot be used outside a react-server environment. ' +
12 | 'You must configure Node.js using the `--conditions react-server` flag.',
13 | );
14 |
--------------------------------------------------------------------------------
/packages/react-server-dom-webpack/server.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | throw new Error(
11 | 'The React Server cannot be used outside a react-server environment. ' +
12 | 'You must configure Node.js using the `--conditions react-server` flag.',
13 | );
14 |
--------------------------------------------------------------------------------
/packages/react-suspense-test-utils/README.md:
--------------------------------------------------------------------------------
1 | # react-suspense-test-utils
2 |
3 | This package is meant to be used alongside yet-to-be-released, experimental React features. It's unlikely to be useful in any other context.
4 |
5 | **Do not use in a real application.** We're publishing this early for
6 | demonstration purposes.
7 |
8 | **Use it at your own risk.**
9 |
10 | # No, Really, It Is Unstable
11 |
12 | The API ~~may~~ will change wildly between versions.
13 |
--------------------------------------------------------------------------------
/.github/ISSUE_TEMPLATE/config.yml:
--------------------------------------------------------------------------------
1 | contact_links:
2 | - name: 📃 Documentation Issue
3 | url: https://github.com/reactjs/reactjs.org/issues/new
4 | about: This issue tracker is not for documentation issues. Please file documentation issues here.
5 | - name: 🤔 Questions and Help
6 | url: https://reactjs.org/community/support.html
7 | about: This issue tracker is not for support questions. Please refer to the React community's help and discussion forums.
8 |
--------------------------------------------------------------------------------
/fixtures/expiration/.gitignore:
--------------------------------------------------------------------------------
1 | # See https://help.github.com/ignore-files/ for more about ignoring files.
2 |
3 | # dependencies
4 | /node_modules
5 |
6 | # testing
7 | /coverage
8 |
9 | # production
10 | /build
11 |
12 | # misc
13 | .DS_Store
14 | .env.local
15 | .env.development.local
16 | .env.test.local
17 | .env.production.local
18 |
19 | npm-debug.log*
20 | yarn-debug.log*
21 | yarn-error.log*
22 |
23 | public/react.development.js
24 | public/react-dom.development.js
--------------------------------------------------------------------------------
/fixtures/fiber-debugger/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "react-fiber-debugger",
3 | "version": "0.0.1",
4 | "private": true,
5 | "devDependencies": {
6 | "react-scripts": "0.9.5"
7 | },
8 | "dependencies": {
9 | "dagre": "^0.7.4",
10 | "pretty-format": "^4.2.1",
11 | "react-draggable": "^2.2.6",
12 | "react-motion": "^0.5.0"
13 | },
14 | "scripts": {
15 | "dev": "react-scripts start",
16 | "build": "react-scripts build"
17 | }
18 | }
19 |
--------------------------------------------------------------------------------
/packages/react-native-renderer/src/ReactNativeEventPluginOrder.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | const ReactNativeEventPluginOrder = [
11 | 'ResponderEventPlugin',
12 | 'ReactNativeBridgeEventPlugin',
13 | ];
14 |
15 | export default ReactNativeEventPluginOrder;
16 |
--------------------------------------------------------------------------------
/packages/shared/ExecutionEnvironment.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | export const canUseDOM: boolean = !!(
11 | typeof window !== 'undefined' &&
12 | typeof window.document !== 'undefined' &&
13 | typeof window.document.createElement !== 'undefined'
14 | );
15 |
--------------------------------------------------------------------------------
/scripts/perf-counters/README.md:
--------------------------------------------------------------------------------
1 | # perf-counters
2 |
3 | Lightweight bindings to Linux perf event counters.
4 |
5 | ```
6 | $ node
7 | > var PerfCounters = require('perf-counters');
8 | > PerfCounters.init();
9 | > var start = PerfCounters.getCounters(); console.log('test'); var end = PerfCounters.getCounters();
10 | test
11 | > start
12 | { instructions: 1382, loads: 421, stores: 309 }
13 | > end
14 | { instructions: 647633, loads: 195771, stores: 133246 }
15 | >
16 | ```
17 |
--------------------------------------------------------------------------------
/scripts/rollup/shims/react-native/ReactFeatureFlags.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @format
8 | * @flow strict-local
9 | */
10 |
11 | 'use strict';
12 |
13 | const ReactFeatureFlags = {
14 | debugRenderPhaseSideEffects: false,
15 | };
16 |
17 | module.exports = ReactFeatureFlags;
18 |
--------------------------------------------------------------------------------
/packages/react-devtools-timeline/src/utils/flow.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 | import type {SchedulingEvent} from '../types';
10 |
11 | export function isStateUpdateEvent(event: SchedulingEvent): boolean %checks {
12 | return event.type === 'schedule-state-update';
13 | }
14 |
--------------------------------------------------------------------------------
/packages/react-native-renderer/src/__mocks__/react-native/Libraries/ReactPrivate/ReactNativePrivateInitializeCore.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow strict
8 | */
9 |
10 | 'use strict';
11 |
12 | // Noop
13 |
14 | // TODO #10932517: Move all initialization callers back into react-native
15 |
--------------------------------------------------------------------------------
/packages/shared/ReactDOMSharedInternals.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) Meta Platforms, Inc. and affiliates.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | *
7 | * @flow
8 | */
9 |
10 | import * as ReactDOM from 'react-dom';
11 |
12 | const ReactDOMSharedInternals =
13 | ReactDOM.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
14 |
15 | export default ReactDOMSharedInternals;
16 |
--------------------------------------------------------------------------------
/scripts/release/build-release-locally-commands/update-version-numbers.js:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env node
2 |
3 | 'use strict';
4 |
5 | const {logPromise, updateVersionsForNext} = require('../utils');
6 | const theme = require('../theme');
7 |
8 | module.exports = async ({reactVersion, tempDirectory, version}) => {
9 | return logPromise(
10 | updateVersionsForNext(tempDirectory, reactVersion, version),
11 | theme`Updating version numbers ({version ${version}})`
12 | );
13 | };
14 |
--------------------------------------------------------------------------------
/.prettierrc.js:
--------------------------------------------------------------------------------
1 | 'use strict';
2 |
3 | const {esNextPaths} = require('./scripts/shared/pathsByLanguageVersion');
4 |
5 | module.exports = {
6 | bracketSpacing: false,
7 | singleQuote: true,
8 | bracketSameLine: true,
9 | trailingComma: 'es5',
10 | printWidth: 80,
11 | parser: 'flow',
12 | arrowParens: 'avoid',
13 | overrides: [
14 | {
15 | files: esNextPaths,
16 | options: {
17 | trailingComma: 'all',
18 | },
19 | },
20 | ],
21 | };
22 |
--------------------------------------------------------------------------------
/fixtures/fiber-debugger/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 | React App
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------