You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
**Note:** Make sure your `tsconfig.json` includes the type declaration file, or place it in a directory that TypeScript automatically includes (like `src/types/` or the root of your project).
355
355
356
-
####Using the `<ProtectedRoute>` component
356
+
### Using the `<ProtectedRoute>` component
357
357
358
358
**Note:** The `<ProtectedRoute>` component requires the `react-router-dom` package to be installed.*
359
359
@@ -373,7 +373,7 @@ import { ProtectedRoute } from '@kinde-oss/kinde-auth-react/react-router';
373
373
-`fallbackPath` (required): Path to redirect to if user doesn't have access
374
374
-`children` (required): React components to render if user has access
375
375
376
-
### Basic examples
376
+
####Basic examples
377
377
378
378
```jsx
379
379
// Protect with single role
@@ -397,7 +397,7 @@ import { ProtectedRoute } from '@kinde-oss/kinde-auth-react/react-router';
397
397
</ProtectedRoute>
398
398
```
399
399
400
-
### Complex access control
400
+
####Complex access control
401
401
402
402
```jsx
403
403
// Multiple criteria - user must have ALL specified requirements
@@ -426,11 +426,11 @@ import { ProtectedRoute } from '@kinde-oss/kinde-auth-react/react-router';
0 commit comments