A simple canvas fingerprinting implementation in browser with specific information used to generate fingerprint
npm install browser-canvas-fingerprintingA simple canvas fingerprinting implementation for browsers.
``bash`
npm i browser-canvas-fingerprinting
`js`
import fingerprint from 'browser-canvas-fingerprinting';
console.log(await fingerprint()); // a unique string
export default async function fingerprint(key = '', Optional_OutputOption = 0)
Get the fingerprint or the data.
key
The site key. Use it to generate a hash that is unique per site.
Optional_OutputOption
- 0 (default): Get a unique string.
- 1: deprecated, do not use.
- 2: Get the canvas element.
export async function getData()`
Get the data used to generate the fingerprint.
Returns an array of string.