Skip to content

Conversation

@pivanov
Copy link
Collaborator

@pivanov pivanov commented Dec 12, 2024

Improving the handling of proxy objects and promises and ensures that complex objects, like Next.js params or URLSearchParams, are inspected accurately without errors or performance issues.

Key Changes:

  • proxy detection and unwrapping
  • Improved handling of Promise and Symbol.iterator edge cases.
  • optimized object inspection by consolidating operations for better performance.

These updates fix bugs in the property inspector and ensure a smoother, error-free experience when dealing with complex object types.

Result:
image

Thanks for the guidance of @RobPruzan 🙇‍♂️

@vercel
Copy link

vercel bot commented Dec 12, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Skipped Deployment
Name Status Preview Comments Updated (UTC)
react-scan ⬜️ Skipped (Inspect) Dec 12, 2024 8:02am

@vercel
Copy link

vercel bot commented Dec 12, 2024

@pivanov is attempting to deploy a commit to the Million Team on Vercel.

A member of the Team first needs to authorize it.

@pkg-pr-new
Copy link

pkg-pr-new bot commented Dec 14, 2024

Open in Stackblitz

npm i https://pkg.pr.new/aidenybai/react-scan@107

commit: 6aaeded

  - Remove unreliable proxy detection and instanceof checks
  - Add safer URLSearchParams handling to prevent Next.js errors
  - Use capability checks instead of type detection
  - Improve error handling for property access

  This addresses issues with proxy detection and type checking in the
  element inspector, making it more reliable across different environments
  while preventing Next.js-specific errors when handling search params.
@pivanov
Copy link
Collaborator Author

pivanov commented Jan 22, 2025

obsolate

@pivanov pivanov closed this Jan 22, 2025
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.

3 participants