Capacitor Zendesk Chat plugin
/!\ The plugin only works for android
and ios
platform. /!\
Installation
npm i capacitor-zendesk-chat
Configuration
Configure plugin
Add your key on capacitor.json
and sync it with npx cap sync
.
Register plugin
Find the init component of your app and register the web plugin.
;; ;
Use it
; const ZendeskChat = Plugins; // Initialize the pluginZendeskChat; // Add Visitor info if neededZendeskChat // Open chatZendeskChat;
Platform: Web/PWA
The plugin is not available on web
platform.
Platform: Android
Import the Zendesk Chat library in build.gradle
...// Note that this is root level repositories container and not the one under 'buildScript'repositories { maven { url 'https://zendesk.jfrog.io/zendesk/repo' }}...dependencies { compile group: 'com.zopim.android', name: 'sdk-api', version: '1.4.2'}...
Register the plugin in com.companyname.appname.MainActivity#onCreate
@Overridepublic void { super.; this.;}
Platform: iOS
On iOS the plugin is registered automatically by Capacitor.