JWTappert / use-zendesk-widget

React hook to add the Zendesk widget to your React app.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

use-zendesk-widget

This is the simplest way to add the Zendesk help widget to your React application!

Introduction

This React hook will enable Zendesk's help widget on your application which can support multiple Zendesk products like live chat, contact form, talk, answer bot, and help center. You can easily customize your support experience with additional settings. Definitely checkout the documentation for this widget to better understand all the options available for customization.

Install

yarn add use-zendesk-widget  OR  npm install use-zendesk-widget

Usage

At the root of your application, or really in any place that is hook friendly, drop the hook in with your zendesk key which can be found in your embed code once you're logged into Zendesk admin.

import useZendeskWidget from 'use-zendesk-widget';

const YourApp = () => {
  useZendeskWidget("your-zendesk-key-here", {
    webWidget: {
      color: { theme: '#61dafb' }
    }
  });
  return <h1>Hello World!</h1>
}

Result

Screen Shot 2021-01-15 at 7 39 57 AM

Resources

Zendesk Web Widget Documentation

License

MIT

About

React hook to add the Zendesk widget to your React app.


Languages

Language:JavaScript 100.0%