# ElementHandle

> What a ref on <SizeGuide>, <FitButton> or <FitElement> gives you.

Source: https://docs.tryyoursize.com/reference/react/element-handle/

*Type* · `@tryyoursize/react`

What a `ref` on `<SizeGuide>`, `<FitButton>` or `<FitElement>` gives you.

```ts
interface ElementHandle
```

## Methods

- **`open`** (`void`, required): Opens the measuring window.
- **`close`** (`void`, required)
- **`getElement`** (`TysElement | null`, required): The underlying SDK element (null before mount).
- **`getRecommendation`** (`Promise<Recommendation>`, required): The shopper's recommended size once known.

## Example

**React**

```tsx
const guide = useRef<ElementHandle>(null);

<SizeGuide ref={guide} product="SKU-123" />
<button onClick={() => guide.current?.open()}>Size help</button>
```
