dyd-util

1.0.9 • Public • Published

#dyd-util

npm i dyd-util -S 下载

###import util from 'dyd-util' 引入

##api.js使用

    import user from './user.js'
    import dydUtil from './dyd-util'
    import {serveUrl} from "./url"
    let util =new dydUtil(serveUrl).util
   
    export util
  
    let api= Object.assign(
        user,
    )
    export api

##main.js 引入

import {api} from './api.js'
Vue.prototype.$api=api

##user.js 使用

import {util} from './api.js'

let user={}
let src='users' //当前接口文件夹
user.createUsers=function(data,callback) {
    util(data,src+'/createUsers',callback)
}
export default user

Readme

Keywords

none

Package Sidebar

Install

npm i dyd-util

Weekly Downloads

1

Version

1.0.9

License

ISC

Unpacked Size

23.1 kB

Total Files

17

Last publish

Collaborators

  • dydw