New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

react-use-hotjar

Package Overview
Dependencies
Maintainers
1
Versions
22
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-use-hotjar - npm Package Compare versions

Comparing version 1.0.3 to 1.0.4

7

CHANGELOG.md

@@ -5,2 +5,9 @@ # Changelog

### [1.0.4](https://github.com/olavoparno/react-use-hotjar/compare/v1.0.3...v1.0.4) (2020-08-11)
### Bug Fixes
* **project:** fix lots of things ([76aabd6](https://github.com/olavoparno/react-use-hotjar/commit/76aabd67e9b51b8a75cf4f3925a455de1271bddc))
### [1.0.3](https://github.com/olavoparno/react-use-hotjar/compare/v1.0.2...v1.0.3) (2020-08-11)

@@ -7,0 +14,0 @@

12

dist/index.es.js
import { useMemo, useCallback } from 'react';
function useAppendHeadScript() {
var appendHeadScript = function (_a) {
var appendHeadScript = useCallback(function (_a) {
var scriptText = _a.scriptText, scriptId = _a.scriptId;

@@ -15,7 +15,7 @@ try {

}
catch (error) {
return error;
catch (_b) {
return false;
}
};
return useMemo(function () { return ({ appendHeadScript: appendHeadScript }); }, []);
}, []);
return useMemo(function () { return ({ appendHeadScript: appendHeadScript }); }, [appendHeadScript]);
}

@@ -39,3 +39,3 @@

try {
var hotjarIdentityScript = "var userId=\"" + userId + "\" || null;window.hj(\"identify\",userId,{" + userInfo + "}});";
var hotjarIdentityScript = "var userId=\"" + userId + "\" || null;window.hj(\"identify\",userId," + userInfo + ");";
var isIdentified = appendHeadScript({

@@ -42,0 +42,0 @@ scriptText: hotjarIdentityScript,

@@ -8,3 +8,3 @@ 'use strict';

function useAppendHeadScript() {
var appendHeadScript = function (_a) {
var appendHeadScript = React.useCallback(function (_a) {
var scriptText = _a.scriptText, scriptId = _a.scriptId;

@@ -20,7 +20,7 @@ try {

}
catch (error) {
return error;
catch (_b) {
return false;
}
};
return React.useMemo(function () { return ({ appendHeadScript: appendHeadScript }); }, []);
}, []);
return React.useMemo(function () { return ({ appendHeadScript: appendHeadScript }); }, [appendHeadScript]);
}

@@ -44,3 +44,3 @@

try {
var hotjarIdentityScript = "var userId=\"" + userId + "\" || null;window.hj(\"identify\",userId,{" + userInfo + "}});";
var hotjarIdentityScript = "var userId=\"" + userId + "\" || null;window.hj(\"identify\",userId," + userInfo + ");";
var isIdentified = appendHeadScript({

@@ -47,0 +47,0 @@ scriptText: hotjarIdentityScript,

{
"name": "react-use-hotjar",
"version": "1.0.3",
"version": "1.0.4",
"description": "Add Hotjar capabilities as custom hooks",

@@ -5,0 +5,0 @@ "author": "Olavo Parno",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc