Skip to content
项目

alibaba/hooks has 14,976 GitHub stars and 2,760 forks. GitHot measured +1 stars in 24 hours. Last checked 2026-11-07 11:27 UTC. Last push 2026-10-27.

这些数字如何统计

A high-quality & reliable React Hooks library. https://alibaba.github.io/hooks/

可以做什么

  • Easy to learn and use
  • Special treatment for functions, avoid closure problems
  • Contains a large number of advanced Hooks that are refined from business scenarios
  • Contains a comprehensive collection of basic Hooks

实测星标增长

24小时
+1
7天
正在收集历史
15天
正在收集历史
1个月
正在收集历史

各周期内的星标净变化,周期相互重叠,并非每日新增。缺失的测量保持空白。星标代表关注度,不代表软件质量。

README.zh-CN.md

原文

一套高质量可靠的 React Hooks 库

NPM version NPM downloads npm Coverage Status npm gzip size Percentage of issues still open Average time to resolve an issue GitHub

English | 简体中文

📚 文档

公告

use-url-state 已改为使用新包名 @ahooks.js/use-url-state 发布。

如果你正在安装或升级这个包,请使用新的包名。

✨ 特性

  • 易学易用
  • 支持 SSR
  • 对输入输出函数做了特殊处理,避免闭包问题
  • 包含大量提炼自业务的高级 Hooks
  • 包含丰富的基础 Hooks
  • 使用 TypeScript 构建,提供完整的类型定义文件

📦 安装

$ npm install --save ahooks
# or
$ yarn add ahooks
# or
$ pnpm add ahooks
# or
$ bun add ahooks

🔨 使用

import { useRequest } from "ahooks";

💻 在线体验

Edit demo for ahooks

🤝 参与共建

$ git clone [email protected]:alibaba/hooks.git
$ cd hooks
$ pnpm run init
$ pnpm start

打开浏览器访问 http://127.0.0.1:8000

我们欢迎所有人参与共建,请参考CONTRIBUTING.MD

感谢所有贡献者:

contributors

👥 交流讨论

ahooks discussion group 1 ahooks discussion group 2 ahooks discussion group 3

探索相关项目