0.1.2 • Published 5 years ago

profitwell-component v0.1.2

Weekly downloads
10
License
MIT
Repository
-
Last release
5 years ago

profitwell-component

npm package

Simple react component to track by profitwell.

Usage

You can add tracking code by following.

import Profitwell from 'profitwell-component';

const App = ({email}) => {
  return (
    <div>
      <h1>Hello World</h1>
      <Profitwell authToken="YOUR_PROFITWELL_TOKEN" email={email} />
    </div>
  )
}

And use shouldNotLoad prop, you can run only specific environment.

import Profitwell from 'profitwell-component';

const App = ({email}) => {
  const isDevelopment = process.env.NODE_ENV !== 'production'
  return (
    <div>
      <h1>Hello World</h1>
      <Profitwell
        authToken="YOUR_PROFITWELL_TOKEN"
        email={email}
        shouldNotLoad={isDevelopment}
      />
    </div>
  )
}
0.1.2

5 years ago

0.1.1

5 years ago

0.1.0

5 years ago

0.0.1

5 years ago