Documentation Menu

FacePop Events

FacePop emits various events that you can listen to with JavaScript. These events allow you to create custom behaviors when users interact with FacePop.

Event Listening Example

// Example of how to listen for FacePop events
window.addEventListener('FacePop:Loaded', function() {
  console.log('FacePop has loaded!');
});

Available Events

Event Description
FacePop:Loaded Fired when the FacePop script has completely loaded
FacePop:Show:Player Fired when the video player opens
FacePop:Show:Toggle Fired when the toggle button appears
FacePop:Minimize Fired when the user clicks the minimize button on the player
FacePop:Close Fired when the user closes FacePop from the toggle
FacePop:Watching Fired when the video initially starts playing
FacePop:Watched Fired when the video finishes playing
FacePop:OnConversion Fired when the user clicks on a CTA button (link, booking, form submission, etc.)

Note:

All events are notification-only and do not emit any additional data. They simply notify that the event has occurred.

Implementation Example

// Track when users view the entire video
window.addEventListener('FacePop:Watched', function() {
  // Send analytics event
  analytics.track('Video Completed');
});

// Track conversions
window.addEventListener('FacePop:OnConversion', function() {
  // Send analytics event
  analytics.track('FacePop Conversion');
});