On May 9, 2024, you will no longer be able to access any of the functionality of the Chat Plugin. Effective immediately, Chat Plugin in guest mode is no longer available. Other features like m.me links will still be available for you to use. https://developers.facebook.com/docs/messenger-platform/discovery/facebook-chat-plugin/
Facebook Customer Chat Plugin for Vue.js
https://dmnCodes.github.io/vue-fb-customer-chat/
Install using npm
$ npm install vue-fb-customer-chat
Install using yarn
$ yarn add vue-fb-customer-chat
For the messenger to work, you need to enable it on Facebook first:
- Go to your Page on Facebook
- Go to
About
and copy the Page ID (https://www.facebook.com/help/1503421039731588) - Go to
Settings
>Messaging
- Complete the setup in the
Add Messenger to your website
, do not forget to add both production and local URLs
import Vue from 'vue'
import VueFbCustomerChat from 'vue-fb-customer-chat'
Vue.use(VueFbCustomerChat, {
page_id: null, // change 'null' to your Facebook Page ID,
theme_color: '#333333', // theme color in HEX
locale: 'en_US', // default 'en_US'
})
Create 'plugins/vue-fb-customer-chat.js'
import Vue from 'vue'
import VueFbCustomerChat from 'vue-fb-customer-chat'
Vue.use(VueFbCustomerChat, {
page_id: null, // change 'null' to your Facebook Page ID,
theme_color: '#333333', // theme color in HEX
locale: 'en_US', // default 'en_US'
})
Add plugin in nuxt.config.js file for plugins section
plugins: [
{ src: '~/plugins/vue-fb-customer-chat.js', ssr: false }
],