项目
在 GitHub 查看
InhiblabCore/vue-hooks-plus
关于
高性能、简洁易用的 Vue 3 Hooks 库 🧲
网站与应用开发可以做什么
- 🏄🏼♂️ Easy to learn and use
- 🔋 Supports SSR
- 🛸 Contains a comprehensive collection of basic Hooks
- 🏟️ A wide range of application scenarios
实测星标增长
- 24小时
- 0
- 7天
- 0
- 15天
- -1
- 1个月
- 0
各周期内的星标净变化,周期相互重叠,并非每日新增。缺失的测量保持空白。星标代表关注度,不代表软件质量。
README.md
原文✨ Features
- 🏄🏼♂️ Easy to learn and use
- 🔋 Supports SSR
- 🛸 Contains a comprehensive collection of basic Hooks
- 🏟️ A wide range of application scenarios
- 🦾 Preferred useRequest, Powerful request middle tier
- 🎪 Interactive demo, immersive
- 🎯 Written in TypeScript with predictable static types
- 🪄 Support the on-demand load, and reduce the packing volume
- 🤺 Playground, there's ample scope for one's abilities
- 🔐 Perfect test, safe and reliable
📦 Install
[!IMPORTANT] Developing, building, and running the documentation for this repository now require Node.js >= 22.18.0. The published hooks still target Vue 3 applications and do not add a Node.js runtime requirement in the browser.
npm i vue-hooks-plus
CDN
<script src="https://cdn.jsdelivr.net/npm/vue-hooks-plus/dist/js/index.iife.js"></script>
It will be exposed to global as VueHooks_Plus
🤹♀️ Usage
import { useRequest } from 'vue-hooks-plus'
Introduced on demand
import useRequest from 'vue-hooks-plus/es/useRequest'
Auto Import
Vite
import AutoImport from 'unplugin-auto-import/vite'
import { VueHooksPlusResolver } from '@vue-hooks-plus/resolvers'
export const AutoImportDeps = () =>
AutoImport({
imports: ['vue', 'vue-router'],
include: [/\.[tj]sx?$/, /\.vue$/, /\.vue\?vue/, /\.md$/],
dts: 'src/auto-imports.d.ts',
resolvers: [VueHooksPlusResolver()],
})
Webpack
const { VueHooksPlusResolver } = require('@vue-hooks-plus/resolvers')
module.exports = {
/* ... */
plugins: [
require('unplugin-auto-import/webpack')({
imports: ['vue', 'vue-router'],
include: [/\.[tj]sx?$/, /\.vue$/, /\.vue\?vue/, /\.md$/],
dts: 'src/auto-imports.d.ts',
resolvers: [VueHooksPlusResolver()],
}),
],
}
For other supported tools, please see unplugin-auto-import
Globalization Documentations
Example
🤩 Awesome
Template
🪴 Project Activity
Contributing
Welcome to join us! You can check out the Contributing Guide to learn how to get started.
Contributors
Thanks for all their contributions 🐝 !
🌸 Thanks
This project is heavily inspired by the following awesome projects.
📄 License
MIT License © 2022-PRESENT YongGit
探索相关项目
加载中…