Skip to content

Commit 805f28a

Browse files
Merge pull request #6 from Expensify/Rory-UpdateTo18.7
Update RNW to 18.7 - This was merged without signed commits as contributors upstream do not use signing.
2 parents 3cd81b5 + 1a362eb commit 805f28a

File tree

509 files changed

+34901
-17566
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

509 files changed

+34901
-17566
lines changed

.codesandbox/ci.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"packages": ["packages/react-native-web", "packages/babel-plugin-react-native-web"],
3+
"buildCommand": "build",
4+
"sandboxes": ["/packages/react-native-web-examples/"],
5+
"node": "16"
6+
}

.flowconfig

Lines changed: 0 additions & 17 deletions
This file was deleted.

.github/CONTRIBUTING.md

Lines changed: 31 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -14,97 +14,79 @@ Fork, then clone the repo:
1414
git clone https://github.com/your-username/react-native-web.git
1515
```
1616

17-
Install dependencies (requires [yarn](https://yarnpkg.com/en/docs/install)):
17+
Install dependencies (requires Node.js >= 16.0):
1818

1919
```
20-
yarn
20+
npm install
2121
```
2222

23-
## Automated tests
23+
## Build
2424

25-
To run the linter:
25+
Build a specific package:
2626

2727
```
28-
yarn lint
28+
npm run build -w <package-name>
2929
```
3030

31-
To run flow:
31+
For example, this will build `react-native-web`:
3232

3333
```
34-
yarn flow
34+
npm run build -w react-native-web
3535
```
3636

37-
To run the unit tests:
37+
Build all packages that can be built:
3838

3939
```
40-
yarn jest
40+
npm run build
4141
```
4242

43-
…in watch mode:
43+
## Develop
4444

45-
```
46-
yarn jest --watch
47-
```
48-
49-
To run all these automated tests:
45+
Develop a specific package:
5046

5147
```
52-
yarn test
48+
npm run dev -w <package-name>
5349
```
5450

55-
## Compile and build
56-
57-
To compile the `react-native-web` source code:
51+
For example, this command will watch and rebuild the `react-native-web` package:
5852

5953
```
60-
yarn compile
54+
npm run dev -w react-native-web
6155
```
6256

63-
…in watch mode:
57+
And this command will watch and rebuild the `react-native-web-examples` package:
6458

6559
```
66-
yarn compile --watch
60+
npm run dev -w react-native-web-examples
6761
```
6862

69-
## Documentation
63+
## Test
7064

71-
To run the documentation website:
65+
Run the monorepo linter:
7266

7367
```
74-
yarn docs
68+
npm run lint
7569
```
7670

77-
## Examples
78-
79-
To run the examples app:
71+
Run the monorepo type checker:
8072

8173
```
82-
yarn examples
74+
npm run flow
8375
```
8476

85-
When you're also making changes to the 'react-native-web' source files, run this command in another process:
77+
Run the monorepo unit tests:
8678

8779
```
88-
yarn compile --watch
80+
npm run unit
8981
```
9082

91-
## Benchmarks
92-
93-
To run the benchmarks locally:
83+
Run all the automated tests:
9484

9585
```
96-
yarn benchmarks
97-
open ./packages/benchmarks/dist/index.html
86+
npm run test
9887
```
9988

100-
To develop against these benchmarks:
101-
102-
```
103-
yarn compile --watch
104-
yarn benchmarks --watch
105-
```
106-
107-
### New Features
89+
## New Features
10890

10991
Please open an issue with a proposal for a new feature or refactoring before starting on the work. We don't want you to waste your efforts on a pull request that we won't want to accept.
11092

@@ -115,19 +97,15 @@ Please open an issue with a proposal for a new feature or refactoring before sta
11597
1. Fork the repository and create your branch from `master`.
11698
2. If you've added code that should be tested, add tests!
11799
3. If you've changed APIs, update the documentation.
118-
4. Ensure the tests pass (`yarn test`).
100+
4. Ensure the tests pass (`npm run test`).
119101

120-
You should see a pre-commit hook run before each commit. If it does not, you may need to reset you Git hookspath:
121-
122-
```
123-
git config --unset core.hookspath
124-
```
102+
You should see a pre-commit hook run before each commit.
125103

126104
You can now submit a pull request, referencing any issues it addresses.
127105

128106
Please try to keep your pull request focused in scope and avoid including unrelated commits.
129107

130-
After you have submitted your pull request, we'll try to get back to you as soon as possible. We may suggest some changes or improvements.
108+
After you have submitted your pull request, it's recommended that **you** perform the first code review. We'll try to get back to you as soon as possible and may suggest changes.
131109

132110
Thank you for contributing!
133111

@@ -136,11 +114,11 @@ Thank you for contributing!
136114
To commit, publish, and push a final version:
137115

138116
```
139-
yarn release <version>
117+
npm run release -- <version> --opt=<opt-code>
140118
```
141119

142120
Release candidates or versions that you'd like to publish to npm, but do not want to produce a commit and push it to GitHub:
143121

144122
```
145-
yarn release <version> --skip-git
123+
npm run release -- <version> --skip-git
146124
```

.github/ISSUE_TEMPLATE/bug.md

Lines changed: 0 additions & 52 deletions
This file was deleted.

.github/ISSUE_TEMPLATE/bug.yml

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
name: Bug report
2+
description: File a bug report
3+
labels: ["bug"]
4+
body:
5+
- type: markdown
6+
attributes:
7+
value: |
8+
Thank you for reporting an issue! Create a test case for your issue by forking this template https://codesandbox.io/s/6lx6ql1w5r
9+
- type: checkboxes
10+
attributes:
11+
label: Is there an existing issue for this?
12+
description: Please search to see if an issue already exists for the bug you encountered.
13+
options:
14+
- label: I have searched the existing issues
15+
required: true
16+
- type: textarea
17+
attributes:
18+
label: Describe the issue
19+
description: Please provide a concise description of what you're experiencing. Providing screenshots is also helpful.
20+
validations:
21+
required: true
22+
- type: textarea
23+
attributes:
24+
label: Expected behavior
25+
description: Please provide a concise description of what you expected to happen.
26+
validations:
27+
required: true
28+
- type: textarea
29+
attributes:
30+
label: Steps to reproduce
31+
description: Please describe the precise steps needed to reproduce the behavior.
32+
placeholder: |
33+
Mention package versions and environment (browser, etc)...
34+
1. ...
35+
2. ...
36+
validations:
37+
required: true
38+
- type: input
39+
attributes:
40+
label: Test case
41+
description: Please provide a link to a reduced test case that reproduces the issue.
42+
placeholder: "https://codesandbox.io/s/6lx6ql1w5r"
43+
validations:
44+
required: true
45+
- type: textarea
46+
attributes:
47+
label: Additional comments
48+
description: You're welcome to provide additional context and proposed solutions.

.github/ISSUE_TEMPLATE/config.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
blank_issues_enabled: false

.github/ISSUE_TEMPLATE/feature.md

Lines changed: 0 additions & 17 deletions
This file was deleted.

.github/ISSUE_TEMPLATE/feature.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: Feature request
2+
description: If you have a suggestion…
3+
labels: ["enhancement"]
4+
body:
5+
- type: markdown
6+
attributes:
7+
value: |
8+
Thank you for suggesting a feature!
9+
- type: checkboxes
10+
attributes:
11+
label: Is there an existing request?
12+
description: Please search open and closed issues to see if this request has already been made.
13+
options:
14+
- label: I have searched for this request
15+
required: true
16+
- type: textarea
17+
attributes:
18+
label: Describe the feature request
19+
description: Please provide a concise description of the request, potential solutions, and addtional context.
20+
validations:
21+
required: true
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
name: react@next integration
2+
3+
on:
4+
schedule:
5+
# Run every Monday at 12:00 (see https://crontab.guru)
6+
- cron: '0 12 * * 1'
7+
8+
jobs:
9+
react-next:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v2
13+
- uses: actions/setup-node@v1
14+
with:
15+
node-version: '16.x'
16+
- run: npm install
17+
# Update react-native-web to use react@next
18+
- run: npm install react@next react-dom@next -w react-native-web
19+
# Run the unit tests
20+
- run: npm run unit

0 commit comments

Comments
 (0)