jzy-vue-utils

1.0.2 • Public • Published
  • learn how to publish vue components and as utils for myself.
  • vue utils 练习参考带你封装一个 vue component ,不过里面对应的 coutup.js 接口变了

使用

  • import 方式

看了一下上传npm的包,了解如何使用tree

<template>
    <CountTo end-val="100"   ></CountTo>
</template>
<script>
import CountTo from 'jzy-vue-utils'
export default {
  components: { CountTo } 
</script>
  • html中使用
<script src="https://unpkg.com/jzy-vue-utils@1.0.1/dist/jzy_vue_components.min.js"></script>
...
<div>
 <count-to end-val="100"   ></count-to>
</div>
 

Build Setup

# install dependencies
npm install

# serve with hot reload at localhost:8080
# 如果是自己测试一下组件 ,配置webpack.config.js 里面放开注释 entry: './src/main.js',
npm run dev

# build 是调用的buid目录里面的webpack 配置
npm run build

For detailed explanation on how things work, consult the docs for vue-loader.

Readme

Keywords

Package Sidebar

Install

npm i jzy-vue-utils

Weekly Downloads

1

Version

1.0.2

License

MIT

Unpacked Size

181 kB

Total Files

17

Last publish

Collaborators

  • jingkeke