# Experience Hooks

## `useIgExperiences()`

Returns a list of experiences the user is assigned to (filtered to active experiences). The returned items are `PluginExperienceType` objects from `@intelligems/ig-types`.

<pre class="language-typescript"><code class="lang-typescript">import type { PluginExperienceType } from "@intelligems/ig-types";

<strong>const useIgExperiences: () => {
</strong>    isReady: boolean;
    experiences: PluginExperienceType[]
}
</code></pre>

## `useIgConfigExperiences()`

Returns all experiences from the active Intelligems configuration file.

<pre><code><strong>const useIgConfigExperiences: () => {
</strong>    isReady: boolean;
    experiences: PluginExperienceType[]
}
</code></pre>

## `useIgPreviewedExperience()`

Returns the experience currently being previewed (or `null` if preview mode is inactive or set to preview all traffic).

```typescript
const useIgPreviewedExperience: () => PluginExperienceType | null;
```
