File: examples/react/src/Components/Contact.js

Recommend this page to a friend!
  Classes of Arturs Sosins  >  Countly Web SDK  >  examples/react/src/Components/Contact.js  >  Download  
File: examples/react/src/Components/Contact.js
Role: Auxiliary script
Content type: text/plain
Description: Auxiliary script
Class: Countly Web SDK
Track site accesses and errors the Countly API
Author: By
Last change:
Date: 2 months ago
Size: 719 bytes


Class file image Download
import React from 'react';
import Countly from 'countly-sdk-web';
import countlyImage from './countly.jpg';

function Contact() {
    const emailUsClick = () => {
        Countly.q.push(['add_event', {
            "key": "email-us-clicked",
            "count": 1
        alert("Email us event triggered");

    return (
        <div className="contact">
                <img src={countlyImage} alt="Home"></img>
                <button className="email-us" onClick={emailUsClick}>Email us</button>

export default Contact;