概述
网络
request
uploadFile
downloadFile
connectSocket
onSocketOpen
closeSocket
sendSocketMessage
onSocketMessage
onSocketError
onSocketClose
交互
showModal
showToast
hideToast
showLoading
hideLoading
showActionSheet
导航
navigateTo
redirectTo
reLaunch
navigateBack
设置导航条
setNavigationBarTitle
setNavigationBarColor
showNavigationBarLoading
hideNavigationBarLoading
TabBar
switchTab
动画
createAnimation
animation
画布
createCanvasContext
CanvasContext.setTextAlign
CanvasContext.setTextBaseline
CanvasContext.setFillStyle
CanvasContext.setStrokeStyle
CanvasContext.setShadow
CanvasContext.createLinearGradient
CanvasContext.createCircularGradient
CanvasGradient.addColorStop
CanvasContext.setLineWidth
CanvasContext.setLineCap
CanvasContext.setLineJoin
CanvasContext.setMiterLimit
CanvasContext.rect
CanvasContext.fillRect
CanvasContext.strokeRect
CanvasContext.clearRect
CanvasContext.fill
CanvasContext.stroke
CanvasContext.beginPath
CanvasContext.closePath
CanvasContext.moveTo
CanvasContext.lineTo
CanvasContext.arc
CanvasContext.bezierCurveTo
CanvasContext.clip
CanvasContext.quadraticCurveTo
CanvasContext.scale
CanvasContext.rotate
CanvasContext.translate
CanvasContext.setFontSize
CanvasContext.fillText
CanvasContext.drawImage
CanvasContext.setGlobalAlpha
CanvasContext.setLineDash
CanvasContext.transform
CanvasContext.setTransform
CanvasContext.save
CanvasContext.restore
CanvasContext.draw
CanvasContext.measureText
CanvasContext.canvastotempfilepathobject
键盘
hideKeyboard
滚动
pageScrollTo
下拉刷新
stopPullDownRefresh
节点查询
createSelectorQuery
SelectorQuery.select
SelectorQuery.selectAll
SelectorQuery.selectViewport
NodesRef.boundingClientRect
NodesRef.scrollOffset
SelectorQuery.exec
图片
chooseImage
previewImage
saveImageToPhotosAlbum
getImageInfo
数据缓存
setStorage
setStorageSync
getStorage
getstoragesync
removeStorage
removeStorageSync
clearStorage
clearStorageSync
getStorageInfo
getStorageInfoSync
文件
getFileInfo
getSavedFileInfo
getSavedFileList
removeSavedFile
saveFile
位置
getLocation
openLocation
chooseLocation
分享
onShareAppMessage
hideShareMenu
设备
振动
vibrateLong
vibrateShort
电话
makePhoneCall
网络
getNetworkType
onNetworkStatusChange
剪切板
getClipboardData
setClipboardData
屏幕
setKeepScreenOn
getScreenBrightness
setScreenBrightness
系统信息
getSystemInfo
getSystemInfoSync
扫码-需要适配支付宝
scanCode
用户截屏事件
onUserCaptureScreen
canIUse
iBeacon
startBeaconDiscovery
stopBeaconDiscovery
getBeacons
onBeaconUpdate
onBeaconServiceChange
文档
已兼容处理的API
谁在用nanachi
关于
键盘
hideKeyboard
隐藏键盘
入参
参数
类型
说明
支持平台
success
Function
接口调用成功的回调函数
微信
fail
Function
接口调用失败的回调函数
微信
complete
Function
接口调用结束的回调函数(调用成功、失败都会执行)
微信
画布
滚动