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
+16-3Lines changed: 16 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -30,6 +30,8 @@ If you don't want to squash your commits, make sure that your commits follow the
30
30
31
31
## Generating code from Open API
32
32
33
+
### Commands
34
+
33
35
Checkout the [protocol](https://github.com/GetStream/protocol) or [chat](https://github.com/GetStream/chat) reporisitories and run one of the following commands:
34
36
35
37
```shell
@@ -39,10 +41,19 @@ $ yarn generate:open-api
39
41
$ yarn generate:open-api:dev
40
42
```
41
43
42
-
Fix manually the known issues issues in the generated code:
44
+
If you want to update only chat or video you need to define the `PRODUCT` env variable like this:
45
+
46
+
```shell
47
+
$ PRODUCT=video yarn generate:open-api
48
+
$ PRODUCT=chat yarn generate:open-api:dev
49
+
```
43
50
44
-
- Add `/** @ts-expect-error */ ` for imports for `ImageSizeRequest`, `OnlyUserIDRequest` in the `gen/chat/FilesApi.ts` and `gen/chat/MessagesApi.ts` files
45
-
- Add `/** @ts-expect-error */ ` for duplicate exports in `gen/chat/index.ts`
51
+
### Fix issues in chat code
52
+
53
+
If you have updated the generated chat code you'll have to fix the following issues manually in the generated code:
54
+
55
+
- Add `/** @ts-expect-error */ ` (make sure to use this exact comment format otherwise they will be missing from `d.ts` files) for imports for `ImageSizeRequest`, `OnlyUserIDRequest` in the `gen/chat/FilesApi.ts` and `gen/chat/MessagesApi.ts` files
56
+
- Add `/** @ts-expect-error */ ` (make sure to use this exact comment format otherwise they will be missing from `d.ts` files) for duplicate exports in `gen/chat/index.ts`
46
57
- Fix the query param serizalization in the `gen/chat/MessagesApi.ts` file's `getManyMessagesRaw` function. This is the correct serialization:
0 commit comments