Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@cyberalien/redundancy

Package Overview
Dependencies
Maintainers
1
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@cyberalien/redundancy - npm Package Compare versions

Comparing version 0.0.5 to 0.0.6

4

lib/code/config.js

@@ -0,7 +1,9 @@

"use strict";
// Allow <any> type because resource can be anything
/* eslint-disable @typescript-eslint/no-explicit-any */
Object.defineProperty(exports, "__esModule", { value: true });
/**
* Default RedundancyConfig for API calls
*/
export const defaultConfig = {
exports.defaultConfig = {
resources: [],

@@ -8,0 +10,0 @@ index: 0,

@@ -0,7 +1,9 @@

"use strict";
// Allow <any> type because query and resource can be anything
/* eslint-disable @typescript-eslint/no-explicit-any */
Object.defineProperty(exports, "__esModule", { value: true });
/**
* Query class
*/
export class Query {
class Query {
constructor(parent, config, payload, queryCallback, doneCallback = null) {

@@ -263,1 +265,2 @@ this.status = 'pending'; // Query status

}
exports.Query = Query;

@@ -0,9 +1,11 @@

"use strict";
// Allow <any> type because query and resource can be anything
/* eslint-disable @typescript-eslint/no-explicit-any */
import { defaultConfig } from './config';
import { Query } from './query';
Object.defineProperty(exports, "__esModule", { value: true });
const config_1 = require("./config");
const query_1 = require("./query");
/**
* Redundancy class
*/
export class Redundancy {
class Redundancy {
/**

@@ -20,3 +22,3 @@ * Constructor. Accepts partial RedundancyConfig object as parameter, merges with defaults

}
this.config = Object.assign({}, defaultConfig, config);
this.config = Object.assign({}, config_1.defaultConfig, config);
this.cleanup = this.cleanup.bind(this);

@@ -28,3 +30,3 @@ }

query(payload, queryCallback, doneCallback = null) {
const query = new Query(this, this.config, payload, queryCallback, doneCallback);
const query = new query_1.Query(this, this.config, payload, queryCallback, doneCallback);
this.queries.push(query);

@@ -67,1 +69,2 @@ return query;

}
exports.Redundancy = Redundancy;

@@ -0,5 +1,7 @@

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
/**
* Interfaces from redundancy.ts
*/
import { Redundancy } from './redundancy';
export { Redundancy };
const redundancy_1 = require("./redundancy");
exports.Redundancy = redundancy_1.Redundancy;
{
"name": "@cyberalien/redundancy",
"description": "Reusable redundancy library for API queries",
"version": "0.0.5",
"version": "0.0.6",
"author": "Vjacheslav Trushkin",

@@ -6,0 +6,0 @@ "license": "(Apache-2.0 OR GPL-2.0)",

@@ -6,3 +6,3 @@ {

"target": "ES2019" /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019' or 'ESNEXT'. */,
"module": "ESNext" /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', or 'ESNext'. */,
"module": "commonjs" /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', or 'ESNext'. */,
// "lib": [], /* Specify library files to be included in the compilation. */

@@ -9,0 +9,0 @@ // "allowJs": true, /* Allow javascript files to be compiled. */

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