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

cycle-hashchange-driver

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cycle-hashchange-driver - npm Package Compare versions

Comparing version 4.0.0 to 5.0.0

10

lib/index.js

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

var _cycleCore = require('@cycle/core');
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
var _rx = require('rx');
var _rx2 = _interopRequireDefault(_rx);
function normalizeHash(hash) {

@@ -16,7 +20,7 @@ return hash.split('#').slice(1).join('#');

function noHashChangeDriver() {
return _cycleCore.Rx.Observable.just(global.location.hash).map(normalizeHash);
return _rx2['default'].Observable.just(global.location.hash).map(normalizeHash);
}
function hashChangeDriver() {
return _cycleCore.Rx.Observable.fromEvent(global, 'hashchange').pluck('newURL').startWith(global.location.hash).map(normalizeHash).distinctUntilChanged();
return _rx2['default'].Observable.fromEvent(global, 'hashchange').pluck('newURL').startWith(global.location.hash).map(normalizeHash).distinctUntilChanged();
}

@@ -23,0 +27,0 @@

{
"name": "cycle-hashchange-driver",
"version": "4.0.0",
"version": "5.0.0",
"description": "A Cycle.js driver for the hashchange event",

@@ -30,4 +30,4 @@ "main": "lib/index.js",

"peerDependencies": {
"@cycle/core": "^4.0.0"
"rx": "^4.0.6"
}
}
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