Skip to content

Commit

Permalink
docs: updating USAGE.md
Browse files Browse the repository at this point in the history
  • Loading branch information
Mhp23 committed Mar 5, 2024
1 parent 97ea996 commit b938f7e
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions USAGE.md
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,20 @@ export default function App() {
}
```

I highly recommend that if you're using `ESLint`, for better debugging and to reduce re-render mistakes due to missing dependencies in your custom hooks and specifically in the `useRStyle` hook, you use the [eslint-plugin-react-hooks](https://github.com/facebook/react/tree/main/packages/eslint-plugin-react-hooks) plugin. Follow its instructions, and add useRStyle to your ESLint rules like this:

```js
{
//...
"rules": {
// ...
"react-hooks/exhaustive-deps": ["warn", {
"additionalHooks": "(useRStyle)"
}]
}
}
```

## responsiveScale (rs)

This function scales the passed size based on the user's device dimensions and base width size and returns the scaled value. It accepts the following arguments:
Expand Down

0 comments on commit b938f7e

Please sign in to comment.