English
Determine whether the application's API, callbacks, parameters, components, etc. are available in the current version.
Platform Difference Description
App | Web | 微信小程序 | 支付宝小程序 | 百度小程序 | 抖音小程序、飞书小程序 | QQ程序 |
---|---|---|---|---|---|---|
√ | √ (uni-app 3.4.13+) | √ | √ | √ | √ | √ |
String parameter description
Use ${API}.${method}.${param}.${options}
or ${component}.${attribute}.${option}
to call, for example:
${API}
represents the API name${method}
represents the calling method, valid values are return, success, object, callback${param}
represents a parameter or return value${options}
represents the optional value of the parameter${component}
represents the component name${attribute}
represents component attributes${option}
represents the optional value of the component propertyExample
uni.canIUse('getSystemInfoSync.return.screenWidth');
uni.canIUse('getSystemInfo.success.screenWidth');
uni.canIUse('showToast.object.image');
uni.canIUse('request.object.method.GET');
uni.canIUse('live-player');
uni.canIUse('text.selectable');
uni.canIUse('button.open-type.contact');
Tips
${API}.${method}.${param}.${options}
call, only ${API}