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

Add rule or no-restricted-syntax config to ban browser globals in React #275

Open
karlhorky opened this issue Sep 25, 2023 · 0 comments
Open
Assignees

Comments

@karlhorky
Copy link
Member

Add new rule or no-restricted-syntax config to ban browser globals like window and document:

  • in a Client Component ('use client' directive) but NOT in useEffect()
  • anywhere in a Server Component (no 'use client' directive)

If considering 3rd-party options, check out:

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

No branches or pull requests

2 participants