https://github.com/carrotquest/gatsby-plugin-dashly
https://github.com/carrotquest/gatsby-plugin-dashly
Last synced: about 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/carrotquest/gatsby-plugin-dashly
- Owner: carrotquest
- Created: 2022-09-13T05:08:05.000Z (over 2 years ago)
- Default Branch: master
- Last Pushed: 2023-04-13T08:14:27.000Z (about 2 years ago)
- Last Synced: 2025-03-01T17:39:58.725Z (3 months ago)
- Language: JavaScript
- Size: 50.8 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# gatsby-plugin-dashly
To integrate [Dashly Conversational platform for business](https://www.dashly.io/) to your Gatsby website, you need to have an account with Dashly. [Sign up](https://www.dashly.io/panel/unauthorized/login/)
With Dashly you can:
1. Collect your users through all the channels including messengers. All users in one inbox, all channels in one user profile.
2. Engage with every user on their terms. Chat, messengers, e-mail are in one user profile.
Never lose track of conversation with your customer
3. Save time for you team, create an automated customer service FAQ chatbot and knowledge base
4. Accelerate growth throughout the customer lifecycle and engage more people with the help of communication tools
5. Qualify leads and focus your sales team on hot ones. Provide the other with self-service## Install
```shell
yarn add gatsby-plugin-dashly
```or
```shell
npm install --save gatsby-plugin-dashly
```
## How to use
To integrate [Live chat](https://www.dashly.io/live-chat/) and [Chatbots](https://www.dashly.io/custom-chatbot/) to your Gatsby site, you need to have an account with Dashly. [Sign up](https://dashly.io/panel/unauthorized/register/).
Upon obtaining your `DASHLY_ID`, you need to modify your `gatsby-config.js` as follows:
```js
// In your gatsby-config.js
module.exports = {
plugins: [
{
resolve: "gatsby-plugin-dashly",
options: {
dashlyId: "DASHLY_ID",
mobileDelay: 2000, // Optional. Delay for mobile devices.
desktopDelay: 500, // Optional. Delay for other devices.
},
},
],
};
```
### Track your pages visits for SPA
```js
// In your gatsby-browser.js
const isEnabledDashly = () => typeof dashly === `object`;exports.onRouteUpdate = ({ location }) => {
if (isEnabledDashly()) {
if (location.href.indexOf("/blog/") > -1) {
dashly.track("Visited blog", {
URL: location.href,
});
} else {
dashly.track("Visited landing", {
URL: location.href,
});
}
}
};
```