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

@xaviw/uicon

v1.1.0

Published

适用于uniapp+uview项目,通过iconfont字体图标自动生成与u-icon一致的图标组件

Downloads

5

Readme

@xavi/uicon

uniapp + UView 项目中快速生成自定义字体图标组件工具

使用方式

  1. iconfont.cn中添加需要的图标至购物车

  2. 点击购物车,将图标添加至项目

  3. 批量操作图标-批量去色(可以跳过)

  4. 项目设置-修改 FontClass/Symbol前缀Font Family(可以跳过)

  5. 查看在线链接或下载至本地

  6. 项目根目录中运行 npx @xavi/uicon 并按提示操作

说明

脚本根据传入的组件创建路径(默认./components/CustomIcon)生成 CustomIcon 组件,内部包括 CustomIcon.vueprops.jsicons.js三个文件

仅支持传入ttf格式的本地或网络字体文件地址

支持选择以网络地址方式链接还是以 Base64 格式内嵌,默认以网络地址方式链接

会按照 uni_modules/uviewnode_modules/uview网络地址 的顺序依次查找 u-icon 源码,如果项目中 uview 源码未保存在 uni_modules 或 node_modules 中还需要修改生成的 vue 代码中 components.scss 引入路径

原理

UView 官方因未实现 nvue 文件扩展字体图标,暂未推出 u-icon 组件扩展图标功能(该组件发布时uview版本号:2.0.36)

但是项目使用中可以直接复制 u-icon 组件,修改 iconfont 字体图标链接以及相关属性,以自定义组件方式实现扩展图标

手动实现复制组件较为麻烦(需要手动录入图标名与 unicode 的对应关系等),使用该工具即可快速生成