Device Feedback
Plugin that lets you provide haptic or acoustic feedback on Android devices.
联系我们?

If you're building a serious project, you can't afford to spend hours troubleshooting. Ionic's experts offer official maintenance, support, and integration help.
Ionic Device Feedback插件的安装(Installation)
Ionic EE comes with fully supported and maintained plugins from the Ionic Team. Learn More or Contact Us
Ionic Device Feedback插件支持的平台(Supported Platforms)
- Android
Ionic Device Feedback插件的用法(Usage)
import { DeviceFeedback } from '@ionic-native/device-feedback/ngx';
constructor(private deviceFeedback: DeviceFeedback) { }
...
this.deviceFeedback.acoustic();
this.deviceFeedback.haptic(0);
this.deviceFeedback.isFeedbackEnabled().then(feedback => {
console.log(feedback);
// {
// acoustic: true,
// haptic: true
// }
});