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

v-ui-template

v1.11.0

Published

Quickly create a component library for Vue 3

Downloads

41

Readme

You can use this project to quickly create a component library based on vue 3.0. This is a super fast and super simple way to generate vue component library!

Documentation

Features

  • Quickly add new components via commands
  • All components support on-demand loading by default
  • Customizable component prefix to avoid component name and style conflicts
  • Support component library document generation

Script commands

For detailed commands, refer to the scripts part of package.json

# Installation dependencies
npm install

# Add new component
npm run gen component-name

# Package your component library
npm run build

# Check the code specification
npm run lint

# Generate log file to release new version
npm run release

# Generate documentation related commands
npm run docs:build

download

# git clone
git clone https://github.com/ckpack/v-ui-template.git

# download zip
https://github.com/ckpack/v-ui-template/archive/refs/heads/main.zip

Global replacement variables

  • v-ui-template is you-project-name such as b-ui
  • ckpack is you-github-username such as my-github-username

Modify component prefix

The default component prefix is ​​V, you can choose to modify the component prefix Modify the file src/defaultConfig.js

// modify the ouput when iife format, such as `BUI`
export const NAME ='BUI';
// Modify the default component prefix, such as `B`
export const COMPONENT_PREFIX ='B';

The default component class prefix is ​​v-, you can choose to modify the component class prefix Modify the file src/styles/__variables.scss

// Modify the default component class prefix such as `b-`
$cls-prefix: b- !default;

Start creating components

Use npm run gen component-name to add new components. For example, execute the npm run gen select command, which will generate the select file directory under the src/components/ directory, and edit the select under the folder. vuefile andindex.scss` file

Preview the newly generated components

Introduce new components in the file dev/app.vue, execute npm run dev to preview the new components

<template>
  <div id="app">
    <ConfigProvider>
+ <Select></Select>
    </ConfigProvider>
  </div>
</template>
<script setup>
import {
+ ConfigProvider, Select,
} from'../src';
</script>

Add new component document

Add the document corresponding to the component name in the docs/guide/compoents folder, execute npm run docs:dev to preview the document

<!-- docs/guide/compoents/select.md -->
# Select

Test component

<v-select></v-select>