Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Convert @bugsnag/plugin-browser-request to TypeScript #2236

Merged

Conversation

AnastasiiaSvietlova
Copy link
Contributor

@AnastasiiaSvietlova AnastasiiaSvietlova commented Oct 23, 2024

Goal

Convert package to TypeScript and ES Modules

Design

Changeset

-Refactor @bugsnag/plugin-browser-request package

Testing

@gingerbenw gingerbenw force-pushed the PLAT-12162-plugin-browser-request branch from 97730a0 to 3c3d2ae Compare October 24, 2024 10:33
Copy link

github-actions bot commented Oct 24, 2024

@bugsnag/browser bundle size diff

Minified Minfied + Gzipped
Before 45.96 kB 13.82 kB
After 45.91 kB 13.79 kB
± -47 bytes -37 bytes

code coverage diff

<temporarily disabled>

Generated by 🚫 dangerJS against 7377476

@gingerbenw gingerbenw force-pushed the PLAT-12162-plugin-browser-request branch from 87cb38e to 6df580b Compare October 24, 2024 13:16
Comment on lines 78 to 81
// @ts-expect-error IE8 onunhandledrejection does not match the signature of the modern listener
win.onunhandledrejection = (reason, promise) => {
// @ts-expect-error detail does not exist on type PromiseRejectionEvent
listener({ detail: { reason, promise } })
listener({ detail: { reason, promise } } as unknown as PromiseRejectionEvent)
}
Copy link
Member

Choose a reason for hiding this comment

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

@tomlongridge have we officially dropped support for IE8 now? this block can go if so 🔥

@AnastasiiaSvietlova AnastasiiaSvietlova merged commit 2866416 into integration/typescript Oct 28, 2024
56 checks passed
@AnastasiiaSvietlova AnastasiiaSvietlova deleted the PLAT-12162-plugin-browser-request branch October 28, 2024 10:07
gingerbenw added a commit that referenced this pull request Nov 12, 2024
* refactor: ♻️ convert plugin-window-onerror to typescript

* update rollup configuration

* Convert plugin-browser-request to TypeScript

* changed tsconfig

* fix: 🩹 update main entry from ts to js

* fix: 🩹 add missing external dependencies to rollup config

* chore: 🏷️ update types and remove ts-expect-error comments

* remove unnecessary rollup config

* chore: 🏷️ fix types

* chore: 🔥 remove IE8 workaround code

* fix: 🩹 fix RN init command

---------

Co-authored-by: Ben Wilson <[email protected]>
gingerbenw added a commit that referenced this pull request Nov 25, 2024
* refactor: ♻️ convert plugin-window-onerror to typescript

* update rollup configuration

* Convert plugin-browser-request to TypeScript

* changed tsconfig

* fix: 🩹 update main entry from ts to js

* fix: 🩹 add missing external dependencies to rollup config

* chore: 🏷️ update types and remove ts-expect-error comments

* remove unnecessary rollup config

* chore: 🏷️ fix types

* chore: 🔥 remove IE8 workaround code

* fix: 🩹 fix RN init command

---------

Co-authored-by: Ben Wilson <[email protected]>
gingerbenw added a commit that referenced this pull request Dec 5, 2024
* refactor: ♻️ convert plugin-window-onerror to typescript

* update rollup configuration

* Convert plugin-browser-request to TypeScript

* changed tsconfig

* fix: 🩹 update main entry from ts to js

* fix: 🩹 add missing external dependencies to rollup config

* chore: 🏷️ update types and remove ts-expect-error comments

* remove unnecessary rollup config

* chore: 🏷️ fix types

* chore: 🔥 remove IE8 workaround code

* fix: 🩹 fix RN init command

---------

Co-authored-by: Ben Wilson <[email protected]>
gingerbenw added a commit that referenced this pull request Dec 5, 2024
* refactor: ♻️ convert plugin-window-onerror to typescript

* update rollup configuration

* Convert plugin-browser-request to TypeScript

* changed tsconfig

* fix: 🩹 update main entry from ts to js

* fix: 🩹 add missing external dependencies to rollup config

* chore: 🏷️ update types and remove ts-expect-error comments

* remove unnecessary rollup config

* chore: 🏷️ fix types

* chore: 🔥 remove IE8 workaround code

* fix: 🩹 fix RN init command

---------

Co-authored-by: Ben Wilson <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants