# @gluestack-ui/utils

> Utility functions and hooks for gluestack-ui

Latest version **5.0.6** (published 2026-06-25) · MIT license · 0 weekly downloads

## Install

```sh
npm install @gluestack-ui/utils
pnpm add @gluestack-ui/utils
yarn add @gluestack-ui/utils
bun add @gluestack-ui/utils
```

## Health

**Score 60/100 (C)** — status: active.

Positive: has types; esm support; no vulnerabilities; high maintenance score.

Warnings: low downloads.

## Facts

| | |
|---|---|
| Version | 5.0.6 |
| Published | 2026-06-25 |
| First published | 2023-02-21 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Node | >=18 |
| Dependencies | 13 |
| Unpacked size | 150.9 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 5347 |
| Maintainers | vidhi499, rohit_singh, viraj-10, rayan1810, rajat693, surajahmedc, meenumakkar, madhavb230100, vaibhk002, daminipandey, amars29, geekgautam, sravankumarvelangi, gluestackadmin, geekashwini, mayankp06, sanchit.kumar, ujjwal2608 |
| Keywords | react, react-native, expo, nextjs, cross-platform, utilities, hooks, aria |

## Links

- npm: https://www.npmjs.com/package/@gluestack-ui/utils
- Repository: https://github.com/gluestack/gluestack-ui
- Homepage: https://github.com/gluestack/gluestack-ui#readme
- Issues: https://github.com/gluestack/gluestack-ui/issues
- npm.io page: https://npm.io/package/@gluestack-ui/utils

## Dependencies (13)

- [react-aria](https://npm.io/package/react-aria.md) ^3.48.0
- [dom-helpers](https://npm.io/package/dom-helpers.md) ^6.0.1
- [react-stately](https://npm.io/package/react-stately.md) ^3.46.0
- [@react-aria/ssr](https://npm.io/package/@react-aria/ssr.md) ^3.9.9
- [@react-aria/focus](https://npm.io/package/@react-aria/focus.md) ^3.21.3
- [@react-aria/utils](https://npm.io/package/@react-aria/utils.md) ^3.32.0
- [tailwind-variants](https://npm.io/package/tailwind-variants.md) 0.1.20
- [@react-aria/dialog](https://npm.io/package/@react-aria/dialog.md) ^3.5.27
- [@react-types/dialog](https://npm.io/package/@react-types/dialog.md) ^3.5.22
- [@react-types/shared](https://npm.io/package/@react-types/shared.md) ^3.33.0
- [@react-stately/toggle](https://npm.io/package/@react-stately/toggle.md) ^3.9.4
- [@react-types/checkbox](https://npm.io/package/@react-types/checkbox.md) ^3.10.2
- [@react-aria/interactions](https://npm.io/package/@react-aria/interactions.md) ^3.26.0

## Alternatives

- [mobx-react](https://npm.io/package/mobx-react.md) — 2.8M weekly downloads
- [rc-tree](https://npm.io/package/rc-tree.md) — 2.6M weekly downloads
- [@react-oauth/google](https://npm.io/package/@react-oauth/google.md) — 1.3M weekly downloads
- [@wagmi/connectors](https://npm.io/package/@wagmi/connectors.md) — 877.0K weekly downloads
- [vee-validate](https://npm.io/package/vee-validate.md) — 836.4K weekly downloads

## Recent versions

- 5.0.6 (latest) — 2026-06-25
- 0.0.0-pr-3394-d42b1c45b-1777455050 (preview) — 2026-04-29
- 5.0.6-alpha.0 (alpha) — 2026-04-17
- 3.0.10-alpha0.1.1 (beta) — 2025-10-13
- 0.0.0-pr-3392-7bcbd2971-1777370286 — 2026-04-28
- 3.0.21 — 2026-04-17
- 5.0.5-alpha.0 — 2026-04-17
- 3.0.20 — 2026-04-17
- 5.0.4-alpha.0 — 2026-03-30
- 3.0.19 — 2026-03-26
- 5.0.3-alpha.0 — 2026-03-26
- 3.0.18 — 2026-03-26
- 3.0.17 — 2026-03-18
- 3.0.16 — 2026-03-18
- 5.0.2-alpha.0 — 2026-03-18
- … 64 more at https://npm.io/package/@gluestack-ui/utils/versions

## README

# @gluestack-ui/utils

A collection of utility functions and hooks for gluestack-ui components.

## Installation

```sh
npm install @gluestack-ui/utils
# or
yarn add @gluestack-ui/utils
```

## Features

- Common utility functions for React and React Native
- Custom React hooks
- NativeWind utilities
- ARIA accessibility helpers

## Usage

```tsx
import {
  useControllableState,
  useKeyboardDismissable,
} from '@gluestack-ui/utils/hooks';
import { mergeRefs, stableHash } from '@gluestack-ui/utils/common';

// Use hooks
const [value, setValue] = useControllableState({
  defaultValue: 'initial',
});

// Use utility functions
const combinedRef = mergeRefs(ref1, ref2);
```

## License

MIT

---
_Source: https://npm.io/package/@gluestack-ui/utils · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
