Skip to content

Latest commit

 

History

History
24 lines (17 loc) · 830 Bytes

track-outbound-links.md

File metadata and controls

24 lines (17 loc) · 830 Bytes

Track Outbound Links

Category: Gatsby

Outbound links point from your website to another and help to improve SEO for your site.

Similar to the <a> href tag, outbound links are used to direct a reader to another source that provides additional information regarding a specific topic.

To use outbound links, install the gatsby-plugin-google-gtag plugin. Substitute the <a> element tag for the <OutboundLink>.

import React from 'react';
import { OutboundLink } from 'gatsby-plugin-google-gtag';

export default () => (
  <div>
    <OutboundLink href='https://www.linkedin.com/in/gregorybsmith'>
      See my LinkedIn profile
    </OutboundLink>
  </div>
);

See Easily add Google Global Site Tag to your Gatsby site for more details.