npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@wfrog/vc

v0.10.1

Published

`自用` 的基于 `element-plus` 二次封装的 `vue3` 组件库。追求在业务场景中,尽可能使用更少的代码量来实现需求。 因此在组件封装上,以 `方便` 为主,打包仅 `esm` 模式。

Downloads

142

Readme

VC 组件库

自用 的基于 element-plus 二次封装的 vue3 组件库。追求在业务场景中,尽可能使用更少的代码量来实现需求。 因此在组件封装上,以 方便 为主,打包仅 esm 模式。

组件开发时,依赖的 vue 版本是 ^3.2.37

组件库所使用 CDN 源为 jsdelivr,并使用了一个自用的函数库 @wfrog/utils

!!!如果 jsdelivr 无法访问,会导致部分组件失效。解决办法:todo

全量引入

本组件库依赖 element-plus,需要事先安装组件中使用的库,以及组件的依赖

npm i element-plus@~2.5.2 @element-plus/icons-vue@^2.0.9 @vueuse/core@^9.1.0
npm i @wfrog/utils@^0.1.0 lodash-es@^4.17.21 vuedraggable@^4.1.0 

然后安装本组件库

npm i @wfrog/vc 

在 app.ts 里,全量引入组件和css

import VC from '@wfrog/vc'
import '@wfrog/vc/es/style.css'

const app = createApp(App)
app.use(VC)

在 vue 文件中使用

<template>
    <HButton :icon="{ type: 'svg', name: 'test' }" type="primary">SVG 图标</HButton>
</template>

单组件加载

本组件库依赖 element-plus,需要事先安装组件中使用的库。组件的依赖可以不按照,仅在使用到有依赖组件的时候才去安装

npm i element-plus@~2.2.13 @element-plus/icons-vue@^2.0.9 @vueuse/core@^9.1.0
npm i @wfrog/utils@^0.1.0 lodash-es@^4.17.21

然后安装本组件库

npm i @wfrog/vc 

在 app.ts 里,全量引入 css

import '@wfrog/vc/es/style.css'

在 vue 文件中

<template>
    <HButton :icon="{ type: 'svg', name: 'test' }" type="primary">SVG 图标</HButton>
</template>

<script lang="ts" setup>
import HButton from '@wfrog/vc/es/components/button'
</script>