Skip to content

cody-ta/react-fbq

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

React Facebook Pixel

React Fbq is a package to help you in yours projects.

React JS wrapper for Facebook's Pixel

Install

npm install --save react-fbq

or

yarn add react-fbq

How to use

import ReactFbq from 'react-fbq';
const advancedMatching = { em: '[email protected]' }; // optional, more info: https://developers.facebook.com/docs/facebook-pixel/advanced/advanced-matching

ReactFbq.initialize({ id: 'yourPixelIdGoesHere', advancedMatching: advancedMatching });
ReactFbq.pageView(); // For tracking page view
ReactFbq.track({ title: event, data: data }); // For tracking default events. More info about standard events: https://developers.facebook.com/docs/facebook-pixel/implementation/conversion-tracking#standard-events

Dev Server

In the folder demo

yarn install
yarn start

Default dev server runs at localhost:4000 in browser. You can set IP and PORT in webpack.config.dev.js

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%