1.1.7 • Published 4 years ago
nfeng-utils v1.1.7
nfeng-utils
轻量提供方法的库,提取项目中使用率高的公用方法
Quick Start
In node.js
1.install
npm i nfeng-utils --save
2.import
import Vue from 'vue'
import NfengUtils from 'nfeng-utils'
Vue.use(NfengUtils, {
network: {
showError: (msg) => {console.log(msg)}
}
})
// 调用更方便
Vue.prototype.$get = Vue.prototype.$nfUtils.network.get
Vue.prototype.$post = Vue.prototype.$nfUtils.network.post
Vue.prototype.$http = Vue.prototype.$nfUtils.network.http
3.usage