🚀 Socket Launch Week Day 5:Introducing Repository Access Permissions and Custom Roles.Learn more
Sign In

@hmflib/ui

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@hmflib/ui

@hmflib ui library

latest
npmnpm
Version
1.0.1
Version published
Maintainers
1
Created
Source

@hmflib/ui

Vue 3 组件库,基于 Vue 3 + TypeScript 构建的现代化组件库。

特性

  • 🚀 基于 Vue 3 + TypeScript 构建
  • 📦 支持按需引入
  • 💪 使用 Monorepo + pnpm 工作区管理
  • 📝 完整的类型定义
  • 🔧 完善的开发工具链

安装

npm install @hmflib/ui

yarn add @hmflib/ui

pnpm add @hmflib/ui

快速开始

全局引入

// main.ts
import { createApp } from 'vue';
import App from './App.vue';

import VUI from '@hmflib/ui';
import '@hmflib/ui/style.css';

const app = createApp(App);
app.use(VUI);
app.mount('#app');

按需引入

// main.ts
import { createApp } from 'vue';
import App from './App.vue';

import { Button } from '@hmflib/ui';
import '@hmflib/ui/style.css';

const app = createApp(App);
app.use(Button);
app.mount('#app');

使用示例

<template>
  <VButton @click="open = true">弹窗</VButton>
  <VButton type="primary">按钮</VButton>
  <VButton type="success">按钮</VButton>
  <VButton type="warning">按钮</VButton>
  <VButton type="danger">按钮</VButton>
  <VButton type="info">按钮</VButton>
  <VDialog v-model:open="open">
    <div> 弹窗测试2222 </div>
  </VDialog>
</template>

<script setup lang="ts">
import { VButton, VDialog } from '@hmflib/ui';
import { ref } from 'vue';
const open = ref(false);
</script>

FAQs

Package last updated on 08 Jan 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts