1.5.0 • Published 4 years ago

fathom-privacy v1.5.0

Weekly downloads
58
License
Apache License 2....
Repository
github
Last release
4 years ago

fathom-npm

npm

Fathom Privacy NPM SDK

This modules serves to simplify integrations with the GDPR enforcement APIs provided by https://fathomprivacy.com

Usage instructions

  1. Install the fathom-privacy package
npm i fathom-privacy --save
  1. Create a div with id="fathom-signup" that will be the sign-up button
<div id="fathom-signup" />
  1. Call the fathom function with your application_id
import fathom from "fathom-privacy"

// Fathom initializes button with id "fathom-signup"
fathom("your-application-id").then((newLookup) => {     
    //when the button is clicked, promise is resolved and returns a newLookup object
    
    newLookup.listenForStatus((message) => {
        //listenForStatus(callback(message)) will run on every new status update
        if (message.status === "in progress") {
            console.log("sign up successful!")
        }

        if (message.status === "complete") {
            //newLookup's getLIData() function will return the data for that user's lookup 
            newLookup.getLIData().then((results) => { console.log(results) })
        }
    })
})
1.5.0

4 years ago

1.4.0

4 years ago

1.3.3

5 years ago

1.3.2

5 years ago

1.3.1

5 years ago

1.3.0

5 years ago

1.2.2

5 years ago

1.2.1

5 years ago

1.2.0

5 years ago

1.1.1

5 years ago

1.1.0

5 years ago