firebase / firebase/firebase-js-sdk
FR: Script injection with defer attribute
- Dominant language
- TypeScript
- Stars
- 5.1k
- Forks
- 1k
- Avg merge
- 2d 21h
- Merged PRs (30d)
- 37
Description
### Operating System
Web
### Browser Version
Any
### Firebase SDK Version
9.20
### Firebase SDK Product:
AppCheck
### Describe your project's tooling
Nuxt with Nuxt Vuefire module
### Describe the problem
The tag `` appended to `<head>` by [this](https://github.com/firebase/firebase-js-sdk/blob/master/packages/app-check/src/recaptcha.ts#L174) or [this](https://github.com/firebase/firebase-js-sdk/blob/master/packages/app-check/src/recaptcha.ts#LL174C10-L174C39) functions is creating Core Web Vitals issues about Total Blocking Time.
Should be there a `defer` attribute to guarantee no blocking.
As you can see here, it is blocking for about 3 seconds.

### Steps and code to reproduce issue
Just use AppCheck and initialize it with Recaptcha Enterprise provider.
Contributor guide
Assessment
This issue has not been assessed yet.