# isIdentified

Learn how to check whether the user is identified.

This method checks whether the current session is associated with an identified user.

> **Best practice**
>
> For better readability, use the [`isAnonymous`](is-anonymous) method instead of a logical negation when checking if the user is anonymous.

## Signature

This method has the following signature:

```ts
user.isIdentified(): boolean
```

This method returns `true` if the user is identified, `false` otherwise.

## Example

Here is a basic example of how to use this method:

```ts
import croct from '@croct/plug';

if (croct.user.isIdentified()) {
  console.log('The user is identified');
} else {
  console.log('The user is anonymous');
}
```
