You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CONTRIBUTING.md
+26-18
Original file line number
Diff line number
Diff line change
@@ -4,52 +4,58 @@ We want this community to be friendly and respectful to each other. Please follo
4
4
5
5
## Development workflow
6
6
7
-
To get started with the project, run `yarn` in the root directory to install the required dependencies for each package:
7
+
To get started with the project, run `bun install` in the root directory to install the required dependencies for each package:
8
8
9
9
```sh
10
-
yarn
10
+
bun install
11
11
```
12
12
13
-
> While it's possible to use [`npm`](https://github.com/npm/cli), the tooling is built around [`yarn`](https://classic.yarnpkg.com/), so you'll have an easier time if you use `yarn` for development.
13
+
> While it's possible to use [`npm`](https://github.com/npm/cli) or [`yarn`](https://yarnpkg.com/cli), the tooling is built around [`bun`](https://bun.sh/), so you'll have an easier time if you use `bun` for development.
14
14
15
15
While developing, you can run the [example app](/example/) to test your changes. Any changes you make in your library's JavaScript code will be reflected in the example app without a rebuild. If you change any native code, then you'll need to rebuild the example app.
16
16
17
+
To install dependencies and pods in example directory:
18
+
19
+
```sh
20
+
bun bootstrap
21
+
```
22
+
17
23
To start the packager:
18
24
19
25
```sh
20
-
yarn examplestart
26
+
bun example:start
21
27
```
22
28
23
29
To run the example app on Android:
24
30
25
31
```sh
26
-
yarn exampleandroid
32
+
bun example:android
27
33
```
28
34
29
35
To run the example app on iOS:
30
36
31
37
```sh
32
-
yarn exampleios
38
+
bun example:ios
33
39
```
34
40
35
41
36
42
Make sure your code passes TypeScript and ESLint. Run the following to verify:
37
43
38
44
```sh
39
-
yarn typescript
40
-
yarn lint
45
+
bun typescript
46
+
bun lint
41
47
```
42
48
43
49
To fix formatting errors, run the following:
44
50
45
51
```sh
46
-
yarn lint --fix
52
+
bun lint --fix
47
53
```
48
54
49
55
Remember to add tests for your change if possible. Run the unit tests by:
50
56
51
57
```sh
52
-
yarntest
58
+
buntest
53
59
```
54
60
To edit the Objective-C files, open `example/ios/PagerViewExample.xcworkspace` in XCode and find the source files at `Pods > Development Pods > react-native-pager-view`.
55
61
@@ -82,20 +88,22 @@ We use [release-it](https://github.com/release-it/release-it) to make it easier
82
88
To publish new versions, run the following:
83
89
84
90
```sh
85
-
yarn release
91
+
bun release
86
92
```
87
93
88
94
### Scripts
89
95
90
96
The `package.json` file contains various scripts for common tasks:
91
97
92
-
-`yarn bootstrap`: setup project by installing all dependencies and pods.
93
-
-`yarn typescript`: type-check files with TypeScript.
94
-
-`yarn lint`: lint files with ESLint.
95
-
-`yarn test`: run unit tests with Jest.
96
-
-`yarn example start`: start the Metro server for the example app.
97
-
-`yarn example android`: run the example app on Android.
98
-
-`yarn example ios`: run the example app on iOS.
98
+
-`bun bootstrap`: setup project by installing all dependencies and pods.
99
+
-`bun typescript`: type-check files with TypeScript.
100
+
-`bun lint`: lint files with ESLint.
101
+
-`bun test`: run unit tests with Jest.
102
+
-`bun example:start`: start the Metro server for the example app.
103
+
-`bun example:android`: run the example app on Android.
104
+
-`bun example:ios`: run the example app on iOS.
105
+
-`bun example:android:release`: run the example app on Android in release mode.
106
+
-`bun example:ios:release`: run the example app on iOS in release mode.
0 commit comments