fingerprinter-js
Version:
A modern JavaScript library for generating unique and reliable browser fingerprints with built-in bot detection
24 lines • 687 B
TypeScript
/**
* Utility functions for fingerprinting
*/
/**
* Simple hash function to convert string to number
*/
export declare function simpleHash(str: string): number;
/**
* Generate SHA-256 hash (using Web Crypto API if available)
*/
export declare function sha256(message: string): Promise<string>;
/**
* Check if running in browser environment
*/
export declare function isBrowser(): boolean;
/**
* Safe JSON stringify that handles circular references
*/
export declare function safeStringify(obj: any): string;
/**
* Get a value safely from an object with error handling
*/
export declare function safeGet<T>(fn: () => T, defaultValue: T): T;
//# sourceMappingURL=utils.d.ts.map