1.0.1 • Published 1 year ago

ylxx-ui-vue2.0 v1.0.1

Weekly downloads
-
License
ISC
Repository
-
Last release
1 year ago

基于vuepress搭建的编写vue2.x的组件库

如何使用

  1. npm i ylxx-ui-vue2.0
  2. 按需加载使用:
plugins: [
    [
      "import",
      {
        libraryName: "ylxx-ui-vue2.0",
        libraryDirectory: "libs",
        style: (name, file) => {
          const libDirIndex = name.lastIndexOf('/')
          const libDir = name.substring(0, libDirIndex)
          let fileName = name.substr(libDirIndex + 1)
          console.log('filenME:', fileName)
          // fileName = fileName.split('-')[1]
          return `${libDir}/theme/${fileName}.css`;
        }
    ]
  1. 代码中如下引入,即可实现按需加载组件
import {YlxxKtitle} form 'ylxx-ui-vue2.0'