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

treble-hook

Package Overview
Dependencies
Maintainers
6
Versions
66
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

treble-hook - npm Package Compare versions

Comparing version

to
0.0.24

2

lib/index.d.ts

@@ -1,2 +0,2 @@

export declare enum TupleIndex {
export declare enum PubSubTupleIndex {
State = 0,

@@ -3,0 +3,0 @@ Publish = 1,

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const react_1 = require("react");
var TupleIndex;
(function (TupleIndex) {
TupleIndex[TupleIndex["State"] = 0] = "State";
TupleIndex[TupleIndex["Publish"] = 1] = "Publish";
TupleIndex[TupleIndex["Unsubscribe"] = 2] = "Unsubscribe";
})(TupleIndex = exports.TupleIndex || (exports.TupleIndex = {}));
var PubSubTupleIndex;
(function (PubSubTupleIndex) {
PubSubTupleIndex[PubSubTupleIndex["State"] = 0] = "State";
PubSubTupleIndex[PubSubTupleIndex["Publish"] = 1] = "Publish";
PubSubTupleIndex[PubSubTupleIndex["Unsubscribe"] = 2] = "Unsubscribe";
})(PubSubTupleIndex = exports.PubSubTupleIndex || (exports.PubSubTupleIndex = {}));
const getUUID = (a, b) => {

@@ -37,3 +37,3 @@ for (b = a = ''; a++ < 36; b += 4 << ~a * 6.5 ? (a ^ 15 ? 8 ^ Math.random() * (a ^ 20 ? 16 : 4) : 4).toString(16) : '-')

if (proceed) {
Object.values(topicRecord.subscriptionMap).forEach(publicHook => publicHook[TupleIndex.Publish](newState));
Object.values(topicRecord.subscriptionMap).forEach(publicHook => publicHook[PubSubTupleIndex.Publish](newState));
topicRecord.currentState = newState;

@@ -40,0 +40,0 @@ topicRecord.hasBeenPublished = true;

{
"name": "treble-hook",
"version": "0.0.23",
"version": "0.0.24",
"description": "Get hooked on simple subscribe-and-publish in ReactJS.",

@@ -5,0 +5,0 @@ "main": "./lib/index.js",

Sorry, the diff of this file is not supported yet