Skip to content

Commit e159c7b

Browse files
authored
FCE-2129 / scope search on current version (#201)
## Description Scopes the search to the current version.
1 parent 6418cf6 commit e159c7b

File tree

5 files changed

+21
-13
lines changed

5 files changed

+21
-13
lines changed

api/fishjam-server

docs/explanation/public-livestreams.mdx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -146,14 +146,14 @@ Once you've created a viewer token, you can connect to a room using the Fishjam
146146

147147
// ...
148148

149-
const { connect } = useLivestreamViewer();
149+
const { connect, whepClientRef } = useLivestreamViewer();
150150

151151
// ...
152152

153153
await connect({ token: viewerToken });
154154

155155
// Use `LivestreamViewer` to render the stream
156-
<LivestreamViewer />
156+
<LivestreamViewer ref={whepClientRef} />
157157
```
158158

159159
</TabItem>
@@ -210,14 +210,14 @@ Once you've created a room of type `livestream` with the `public` flag enabled,
210210

211211
// ...
212212

213-
const { connect } = useLivestreamViewer();
213+
const { connect, whepClientRef } = useLivestreamViewer();
214214

215215
// ...
216216

217217
await connect({ streamId: roomId });
218218

219219
// Use `LivestreamViewer` to render the stream
220-
<LivestreamViewer />
220+
<LivestreamViewer ref={whepClientRef} />
221221
```
222222

223223
</TabItem>

docs/tutorials/livestreaming.mdx

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -161,17 +161,14 @@ We can now start sending media, which we can obtain from the user's camera, scre
161161

162162
const streamerToken = '';
163163
const roomId = '';
164-
const { connect, whipClientRef } = useLivestreamStreamer();
164+
const { connect, whipClientRef } = useLivestreamStreamer({ videoEnabled: true, audioEnabled: true, camera: cameras[0] });
165165

166166
// ...
167167

168168
await connect(streamerToken);
169169

170170
// Render the livestream
171171
<LivestreamStreamer
172-
videoEnabled={true}
173-
audioEnabled={true}
174-
camera={cameras[0]}
175172
whipClientRef={whipClientRef}
176173
/>
177174
```
@@ -262,12 +259,12 @@ We can now begin receiving the stream
262259
useLivestreamViewer,
263260
} from '@fishjam-cloud/react-native-client/livestream';
264261

265-
const { connect } = useLivestreamViewer();
262+
const { connect, whepClientRef } = useLivestreamViewer();
266263

267264
await connect({ token: viewerToken });
268265

269266
// Render the livestream
270-
<LivestreamViewer />
267+
<LivestreamViewer ref={whepClientRef} />
271268
```
272269

273270
</TabItem>

docusaurus.config.ts

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,18 @@ const config: Config = {
266266
} satisfies Preset.ThemeConfig,
267267

268268
plugins: [
269-
require.resolve("docusaurus-lunr-search"),
269+
[
270+
require.resolve("docusaurus-lunr-search"),
271+
// exclude old versions and next from search
272+
{
273+
includeRoutes: [
274+
"/tutorials/*",
275+
"/how-to/*",
276+
"/explanation/*",
277+
"/api/*",
278+
],
279+
},
280+
],
270281
[
271282
"docusaurus-plugin-typedoc",
272283
{

packages/mobile-client-sdk

Submodule mobile-client-sdk updated 53 files

0 commit comments

Comments
 (0)