Clerk types
Types are a powerful tool for adding type-safety to your application. They can help you catch bugs early, make your code easier to understand, and make your code easier to refactor. Clerk provides a number of types to help you add type-safety to your application.
To get access to Clerk types, you need to add the @clerk/shared package to your project. Run the following command to install it:
npm install @clerk/sharedpnpm add @clerk/sharedyarn add @clerk/sharedbun add @clerk/sharedThen, import the types from the @clerk/shared/types entrypoint using a type-only import:
import type { UserResource } from '@clerk/shared/types'Feedback
Last updated on