Skip to content

Commit

Permalink
Adjust cursors default outboundBatchInterval
Browse files Browse the repository at this point in the history
  • Loading branch information
JoaoDiasAbly committed Nov 15, 2024
1 parent 9b74209 commit 87f68f1
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/Cursors.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ describe('Cursors', () => {
vi.spyOn(channel.presence, 'get').mockImplementation(createPresenceCount(2));
await cursors['onPresenceUpdate']();
expect(batching.shouldSend).toBeTruthy();
expect(batching.batchTime).toEqual(25);
expect(batching.batchTime).toEqual(50);
});

it<CursorsTestContext>('batchTime is updated when multiple people are present', async ({
Expand All @@ -126,7 +126,7 @@ describe('Cursors', () => {
}) => {
vi.spyOn(channel.presence, 'get').mockImplementation(createPresenceCount(2));
await cursors['onPresenceUpdate']();
expect(batching.batchTime).toEqual(25);
expect(batching.batchTime).toEqual(50);
});

describe('pushCursorPosition', () => {
Expand Down
2 changes: 1 addition & 1 deletion src/Space.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ const SPACE_CHANNEL_TAG = '::$space';
const SPACE_OPTIONS_DEFAULTS = {
offlineTimeout: 120_000,
cursors: {
outboundBatchInterval: 25,
outboundBatchInterval: 50,
paginationLimit: 5,
},
};
Expand Down

0 comments on commit 87f68f1

Please sign in to comment.