Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

set-fb-cookies

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

set-fb-cookies

Set _fbc and _fbp when Facebook Pixel doesn't

  • 0.0.3
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

Set Facebook Cookies

This simple script sets the _fbp and _fbc cookies when Pixel doesn't.

In Belgium, the served Pixel script is different than in the rest of the world: it's missing pieces of code for handling first-party cookies. This affects other parts of the Pixel code including the correct handling of tracking in iOS 14.5+, and prevents us from reading the cookies for use with the Conversion API.

This package is reimplements the missing piece of the Pixel which sets _fbc and _fbp.

<script async defer src="https://unpkg.com/set-fb-cookies">
import setFbCookies from "set-fb-cookies";

setFbCookies();
const setFbCookies = require("set-fb-cookies").default;

setFbCookies();

Better yet, if you want to use only the Conversion API you can use this script to generate _fbc and _fbp which you can then pass to your Server. This makes it possible to skip using the browser Pixel.

FAQs

Package last updated on 03 Feb 2022

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc