gnosis SafeApp introduces a 300ms pageload timeout
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 5.5k
- Forks
- 5.4k
- PR merge metrics
- No merged PRs in 30d
Description
To use the gnosis SafeApp, you must check for it before using other injectors, so it sits in the pageload critical path.
To check for SafeApp, the SDK races an iframe postMessage with a 300ms timeout (see https://github.com/gnosis/safe-apps-sdk/blob/master/packages/safe-apps-web3-react/src/connector.ts#L52). This should be skipped if we are not in an iframe, and there should be an immediate, deterministic way to tell if we are in a SafeApp.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with packages/safe-apps-web3-react/src/connector.ts at the referenced SafeApp check and trace how the iframe postMessage timeout is used before other injectors. Verify the iframe condition and the requested deterministic SafeApp signal; done means non-iframe page loads no longer wait 300ms while SafeApp detection remains reliable.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100