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

light-observable

Package Overview
Dependencies
Maintainers
1
Versions
32
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

light-observable - npm Package Compare versions

Comparing version 2.0.0-beta.0 to 2.0.0-beta.1

es/extras/skipRepeats.d.ts

1

es/extras/index.d.ts

@@ -8,3 +8,4 @@ export { createSubject } from './subject';

export { pipe } from './pipe';
export { skipRepeats } from './skipRepeats';
export { tap } from './tap';
export { throttle } from './throttle';

@@ -8,4 +8,5 @@ export { createSubject } from './subject';

export { pipe } from './pipe';
export { skipRepeats } from './skipRepeats';
export { tap } from './tap';
export { throttle } from './throttle';
//# sourceMappingURL=index.js.map

@@ -348,2 +348,26 @@ 'use strict';

const defaultEquals = (a, b) => a === b;
const skip = (equals) => {
let init = true;
let oldValue;
return (observer, value) => {
if (init) {
init = false;
oldValue = value;
observer.next(value);
return;
}
if (equals(oldValue, value)) {
return;
}
oldValue = value;
observer.next(value);
};
};
const skipRepeats = (equals = defaultEquals) => {
return (stream) => {
return transform(stream, skip(equals));
};
};
const tap = (fn) => {

@@ -391,3 +415,4 @@ return (stream) => {

exports.pipe = pipe;
exports.skipRepeats = skipRepeats;
exports.tap = tap;
exports.throttle = throttle$1;

2

package.json
{
"name": "light-observable",
"version": "2.0.0-beta.0",
"version": "2.0.0-beta.1",
"description": "Light observable ponyfill",

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

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