Skip to content

joebrust/In-App-Offline-Tracking

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 

Repository files navigation

In-App Offline Tracking

Some apps offer offline content to their users for when they lose internet connection or service. Of those apps, some still provided the ability to serve ads. Since the user was offline, their interactions and impressions need a way to be tracked. The in-app SDK, AdMarvel, offered a solution using local storage but only apps that used that SDK could use their tracking solution. In order to accommodate the increasing request for offline tracking, I adapted their solution to work using the device's local storage. When the user is interacting with the ad, the library checks if the user is online or offline. If they're online, all tracking fires off as per usual. If not, their tracking is stored locally. As soon as the user goes back online, the ad checks to see if any interactions have been stored and if so, fires it off.

Usage

IN order to use, the library must be included in the ad package. You must then also include the pixel url strings within the library along with the unique IDs associated with each interaction. THe library will track impressions, clicks, and activities. Once added, the impression will automatically fire on ad load. To fire a click, call click('insert_click_name'). To track an activity, call track('insert_activity_name').

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors