Skip to content

aiyingya/fmt-wxapp-promise

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

fmtr-wxapp-promise 继wxapp-promise1.0.4之后

turn api of wxapp to promise 把微信小程序 api 转成 promise. 功能是从 labrador 提取得到。 实现参考由weapp-promise提供。

getApp()

import * as wx from 'fmt-wxapp-promise';
const app = wx.app;

promise

import * as wx from 'fmt-wxapp-promise';
async login() {
  await wx.login();
}

finally方法

方法内为一个可执行函数

server.listen(0).then(res=>{}).finally(server.stop)

Installation

npm install fmt-wxapp-promise
或
yarn add fmt-wxapp-promise

Thanks

labrador weapp-promise

Other

更多配置信息可以参考一下vue的package.json vue-package

About

把微信小程序 api 封装 promise

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published