A framework for building native applications using React
Go to file
Alex Hunt 0a3c55562b Update custom "exports" conditions in Jest environment
Summary:
Updates the default set of `"exports"` condition names in our `ReactNativeEnv` for Jest, so that it aligns with the defaults in React Native CLI (https://github.com/react-native-community/cli/pull/1862).

Also includes a subtle update to how this is accomplished. Instead of overriding `exportConditions()`, we assign to the underlying class property — this allows users (once https://github.com/facebook/jest/pull/13989 is merged) to override `customExportConditions` via [`testEnvironmentOptions`](https://jestjs.io/docs/configuration#testenvironmentoptions-object).

```js
  preset: 'react-native',
  testEnvironmentOptions: {
    customExportConditions: ['test', 'react-native'],
  },
```

Changelog: [Internal]

Reviewed By: jacdebug

Differential Revision: D43879056

fbshipit-source-id: 86fffe2b5fdf9d8492d25b8b12a78be75b5fa3be
2023-03-15 17:18:08 -07:00
.bundle
.circleci Use RN Build Utils for Building Hermes Artifacts 2023-03-15 11:13:17 -07:00
.github
android
docs
flow
flow-typed/npm
gradle
IntegrationTests
jest Update custom "exports" conditions in Jest environment 2023-03-15 17:18:08 -07:00
keystores
Libraries Use SocketRocket for web socket library (#36471) 2023-03-15 13:32:59 -07:00
local-cli
packages Use SocketRocket for web socket library (#36471) 2023-03-15 13:32:59 -07:00
React Use SocketRocket for web socket library (#36471) 2023-03-15 13:32:59 -07:00
ReactAndroid Refactor usages of TextLayoutManager.sTextPaintInstance 2023-03-15 16:03:39 -07:00
ReactCommon Disable Android platform for more failing tests 2023-03-15 04:08:19 -07:00
repo-config
scripts Extracting Platform Specific TM code to break dependency cycle between ReactCommon and React-Core (#36461) 2023-03-14 05:31:16 -07:00
sdks/hermes-engine
template
third-party-podspecs
tools
types
.babelrc
.buckconfig
.buckjavaargs
.clang-format
.editorconfig
.eslintignore
.eslintrc.js
.flowconfig Remove inference_mode config now that LTI is the default 2023-03-09 11:01:31 -08:00
.flowconfig.android Remove inference_mode config now that LTI is the default 2023-03-09 11:01:31 -08:00
.gitignore
.prettierrc
BUCK Use SocketRocket for web socket library (#36471) 2023-03-15 13:32:59 -07:00
build.gradle.kts
CHANGELOG.md add 0.71.4 changelog (#36405) 2023-03-09 01:27:43 -08:00
cli.js
CODE_OF_CONDUCT.md
CONTRIBUTING.md
ECOSYSTEM.md
Gemfile
Gemfile.lock
gradle.properties
gradlew
gradlew.bat
index.js
interface.js
jest-preset.js
jest.config.js
LICENSE
LICENSE-docs
metro.config.js
package.json Back out D43959013 - [hermes] Update the hermes packages to 0.10.0 in 'fbsource' 2023-03-15 08:38:44 -07:00
React-Core.podspec Use SocketRocket for web socket library (#36471) 2023-03-15 13:32:59 -07:00
react-native.config.js
React.podspec
README.md
rn-get-polyfills.js
runXcodeTests.sh
settings.gradle.kts
template.config.js
yarn.lock Back out D43959013 - [hermes] Update the hermes packages to 0.10.0 in 'fbsource' 2023-03-15 08:38:44 -07:00

React Native

Learn once, write anywhere:
Build mobile apps with React.

React Native is released under the MIT license. Current CircleCI build status. Current npm package version. PRs welcome! Follow @reactnative

Getting Started · Learn the Basics · Showcase · Contribute · Community · Support

React Native brings React's declarative UI framework to iOS and Android. With React Native, you use native UI controls and have full access to the native platform.

  • Declarative. React makes it painless to create interactive UIs. Declarative views make your code more predictable and easier to debug.
  • Component-Based. Build encapsulated components that manage their state, then compose them to make complex UIs.
  • Developer Velocity. See local changes in seconds. Changes to JavaScript code can be live reloaded without rebuilding the native app.
  • Portability. Reuse code across iOS, Android, and other platforms.

React Native is developed and supported by many companies and individual core contributors. Find out more in our ecosystem overview.

Contents

📋 Requirements

React Native apps may target iOS 12.4 and Android 5.0 (API 21) or newer. You may use Windows, macOS, or Linux as your development operating system, though building and running iOS apps is limited to macOS. Tools like Expo can be used to work around this.

🎉 Building your first React Native app

Follow the Getting Started guide. The recommended way to install React Native depends on your project. Here you can find short guides for the most common scenarios:

📖 Documentation

The full documentation for React Native can be found on our website.

The React Native documentation discusses components, APIs, and topics that are specific to React Native. For further documentation on the React API that is shared between React Native and React DOM, refer to the React documentation.

The source for the React Native documentation and website is hosted on a separate repo, @facebook/react-native-website.

🚀 Upgrading

Upgrading to new versions of React Native may give you access to more APIs, views, developer tools, and other goodies. See the Upgrading Guide for instructions.

React Native releases are discussed in this discussion repo.

👏 How to Contribute

The main purpose of this repository is to continue evolving React Native core. We want to make contributing to this project as easy and transparent as possible, and we are grateful to the community for contributing bug fixes and improvements. Read below to learn how you can take part in improving React Native.

Code of Conduct

Facebook has adopted a Code of Conduct that we expect project participants to adhere to. Please read the full text so that you can understand what actions will and will not be tolerated.

Contributing Guide

Read our Contributing Guide to learn about our development process, how to propose bugfixes and improvements, and how to build and test your changes to React Native.

Open Source Roadmap

You can learn more about our vision for React Native in the Roadmap.

Good First Issues

We have a list of good first issues that contain bugs which have a relatively limited scope. This is a great place to get started, gain experience, and get familiar with our contribution process.

Discussions

Larger discussions and proposals are discussed in @react-native-community/discussions-and-proposals.

📄 License

React Native is MIT licensed, as found in the LICENSE file.

React Native documentation is Creative Commons licensed, as found in the LICENSE-docs file.