mirror of
https://github.com/facebook/docusaurus.git
synced 2025-12-25 17:22:50 +00:00
docs(eslint-plugin): fix typo in no-window-eq-undefined rule documentation
This commit is contained in:
parent
b11d390ccd
commit
21e55fe431
|
|
@ -6,7 +6,7 @@ slug: /api/misc/@docusaurus/eslint-plugin/no-window-eq-undefined
|
|||
|
||||
Enforce not using typeof window, window === undefined, or any similar expression to detect the SSR (Server-Side Rendering) environment.
|
||||
|
||||
In Docusaurus, it's recommended to safely separate client-side code using the `**@docusaurus/useIsBrowser**` hook or React lifecycle methods like `**useEffect**`.
|
||||
In Docusaurus, it's recommended to safely separate client-side code using the `@docusaurus/useIsBrowser` hook or React lifecycle methods like `useEffect`.
|
||||
|
||||
## Motivation and Rationale
|
||||
|
||||
|
|
@ -20,7 +20,7 @@ However, in React applications, especially those using SSR like Docusaurus, this
|
|||
|
||||
## Rule Details {#details}
|
||||
|
||||
Examples of **incorrect** code for this rule:
|
||||
** Examples of **incorrect** code for this rule ** :
|
||||
|
||||
```js
|
||||
import React from 'react';
|
||||
|
|
@ -44,7 +44,7 @@ The following code uses banned patterns to conditionally render or execute logic
|
|||
|
||||
---
|
||||
|
||||
Examples of **correct** code for this rule:
|
||||
**Examples of **correct** code for this rule** :
|
||||
|
||||
```jsx
|
||||
import React from 'react';
|
||||
|
|
|
|||
Loading…
Reference in New Issue