Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 10 additions & 10 deletions .browserslistrc
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
safari >= 11.1
ios_saf >= 11.3
chrome >= 64
and_chr >= 64
android >= 64
firefox >= 58
and_ff >= 58
edge >= 79
Opera >= 52
Samsung >= 9.2
safari >= 14.1
ios_saf >= 14.5
chrome >= 100
and_chr >= 100
android >= 100
firefox >= 102
and_ff >= 100
edge >= 100
Opera >= 100
Samsung >= 15
Comment on lines +1 to +10
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

chore: I know you had said you made this change based on the apis that the client sdk is currently using in slack, but maybe it's worth digging a bit into the analytics and seeing what browsers / environments users are using this sdk in? I have had a longstanding todo list item to do this but it's been fairly low priority. But it worries me a bit to just wholesale update these without any data to back it up.

not IE 11
not dead
11 changes: 10 additions & 1 deletion .eslintrc.cjs
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
module.exports = {
root: true,
extends: ['plugin:import/recommended', 'airbnb-typescript/base', 'prettier'],
plugins: ['compat'],
extends: [
'plugin:import/recommended',
'airbnb-typescript/base',
'prettier',
'plugin:compat/recommended',
],
parserOptions: {
project: './tsconfig.eslint.json',
},
Expand All @@ -15,4 +21,7 @@ module.exports = {
'no-underscore-dangle': 'off',
'@typescript-eslint/no-use-before-define': 'off',
},
env: {
browser: true,
},
};
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@
"eslint": "8.57.1",
"eslint-config-airbnb-typescript": "18.0.0",
"eslint-config-prettier": "10.1.8",
"eslint-plugin-compat": "^6.0.2",
"eslint-plugin-ecmascript-compat": "^3.2.1",
"eslint-plugin-import": "2.32.0",
"gh-pages": "6.3.0",
Expand Down
59 changes: 55 additions & 4 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions src/room/Room.ts
Original file line number Diff line number Diff line change
Expand Up @@ -576,6 +576,7 @@ class Room extends (EventEmitter as new () => TypedEmitter<RoomEventCallbacks>)

static cleanupRegistry =
typeof FinalizationRegistry !== 'undefined' &&
// eslint-disable-next-line compat/compat
new FinalizationRegistry((cleanup: () => void) => {
cleanup();
});
Expand Down
2 changes: 2 additions & 0 deletions src/room/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -210,6 +210,7 @@ export function isMobile(): boolean {

return (
// @ts-expect-error `userAgentData` is not yet part of typescript
// eslint-disable-next-line compat/compat
navigator.userAgentData?.mobile ??
/Tablet|iPad|Mobile|Android|BlackBerry/.test(navigator.userAgent)
);
Expand Down Expand Up @@ -670,6 +671,7 @@ export function bigIntToNumber<T extends BigInt | undefined>(
export function numberToBigInt<T extends number | undefined>(
value: T,
): T extends number ? bigint : undefined {
// eslint-disable-next-line compat/compat
return (value !== undefined ? BigInt(value) : undefined) as T extends number ? bigint : undefined;
}

Expand Down
Loading