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

nek-vue

Package Overview
Dependencies
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nek-vue

nek-ui by vue

latest
Source
npmnpm
Version
0.1.3
Version published
Weekly downloads
21
-57.14%
Maintainers
1
Weekly downloads
 
Created
Source

nek-vue

UI components based on [Vue.js]

Build Status npm

Install nek-vue

using npm

npm install nek-vue --save

Usage

import nek from 'nek-vue'
import 'nek-vue/lib/style/index.css'
Vue.use(nek)

按需引用

借助 babel-plugin-component,我们可以只引入需要的组件,以达到减小项目体积的目的。

首先,安装 babel-plugin-component:

npm install babel-plugin-component -D

然后,在 .babelrc 添加如下配置:

  "plugins": [["component", [
    {
      "libraryName": "nek-vue",
      "styleLibraryName": "style",
      "styleLibrary": {
        "name": "/",
        "base": true,
        "path": "[module]/style/index.css",
        "mixin": false
      },
      "camel2Dash": true
    }
  ]]]

接下来,如果你只希望引入部分组件,比如 Button 和 Select,那么需要在 main.js 中写入以下内容:

import { Button } from 'nek-vue'
Vue.component(Button.name, Button)

LICENSE

MIT

Keywords

vue

FAQs

Package last updated on 17 Jul 2018

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