Skip to content
This repository has been archived by the owner on Aug 26, 2022. It is now read-only.

Integrate Intercom into your Nuxt app

License

Notifications You must be signed in to change notification settings

extracard/nuxt-intercom

 
 

Repository files navigation

nuxt-intercom

npm version npm downloads Circle CI Codecov License

Intercom Module for Nuxt.js

🚀 Demo Site available here

📖 Release Notes

Setup

  1. Add @hexdigital/nuxt-intercom dependency to your project
yarn add @hexdigital/nuxt-intercom # or npm install @hexdigital/nuxt-intercom

Add @hexdigital/nuxt-intercom to the buildModules section of nuxt.config.js

{
  buildModules: [
    '@hexdigital/nuxt-intercom',
  ],
  intercom: {
    appId: 'XXXXXXXXXX',
  },
}

Options

Defaults:

const defaults = {
  appId: null, // Intercom ID
  autoBoot: true, // True to boot messenger widget and show UI on page load, false to allow manually booting later
  debug: false, // True to show debug messages in the console, useful for development, false to not show them
    
  scriptId: 'intercom-script', // String to identfy the script tag, for vue-meta
  scriptDefer: false, // True to defer loading intercom widget javascript until page loads, false to async load it in document flow
    
  updateOnPageRoute: true // True to call intercom's 'update' method on route change, false to not do this
};

Usage

Development

  1. Clone this repository
  2. Install devDependencies using yarn install
  3. Start development server using yarn dev or INTERCOM_ID=<your intercom id> yarn dev if you want to provide customer INTERCOM_ID.

License

MIT License

Copyright (c) Hex Digital

About

Integrate Intercom into your Nuxt app

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 98.5%
  • Vue 1.5%