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

cycle-gear

Package Overview
Dependencies
Maintainers
1
Versions
29
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cycle-gear - npm Package Compare versions

Comparing version 3.0.0 to 3.1.0

2

dist-es2015/index.d.ts

@@ -13,3 +13,3 @@ import * as Rx from 'rx';

export interface Gear<TActions, TModel> {
catch?: (error: any) => Rx.Observable<any>;
catch?: (error: any, actions: TActions) => Rx.Observable<any>;
intent?: (sources: any) => TActions;

@@ -16,0 +16,0 @@ model?: (actions: TActions) => Rx.Observable<TModel>;

@@ -51,4 +51,4 @@ import * as Rx from 'rx';

const actions = gear.intent ? gear.intent(sources) : defaultIntent(sources);
const state$ = (gear.model ? gear.model(actions) : defaultModel(sources))
.catch(gear.catch ? gear.catch : defaultCatch)
const state$ = (gear.model ? gear.model(actions) : defaultModel(actions))
.catch((err) => gear.catch ? gear.catch(err, actions) : defaultCatch(err, actions))
.shareReplay(1);

@@ -55,0 +55,0 @@ const views = teeth.reduce((accum, tooth) => Object.assign(accum, {

@@ -13,3 +13,3 @@ import * as Rx from 'rx';

export interface Gear<TActions, TModel> {
catch?: (error: any) => Rx.Observable<any>;
catch?: (error: any, actions: TActions) => Rx.Observable<any>;
intent?: (sources: any) => TActions;

@@ -16,0 +16,0 @@ model?: (actions: TActions) => Rx.Observable<TModel>;

@@ -57,4 +57,4 @@ "use strict";

var actions = gear.intent ? gear.intent(sources) : defaultIntent(sources);
var state$ = (gear.model ? gear.model(actions) : defaultModel(sources))
.catch(gear.catch ? gear.catch : defaultCatch)
var state$ = (gear.model ? gear.model(actions) : defaultModel(actions))
.catch(function (err) { return gear.catch ? gear.catch(err, actions) : defaultCatch(err, actions); })
.shareReplay(1);

@@ -61,0 +61,0 @@ var views = teeth.reduce(function (accum, tooth) {

@@ -17,3 +17,3 @@ import * as Rx from 'rx'

export interface Gear<TActions, TModel> {
catch?: (error: any) => Rx.Observable<any>
catch?: (error: any, actions: TActions) => Rx.Observable<any>
intent?: (sources: any) => TActions

@@ -85,4 +85,4 @@ model?: (actions: TActions) => Rx.Observable<TModel>

const actions = gear.intent ? gear.intent(sources) : defaultIntent(sources)
const state$ = (gear.model ? gear.model(actions) : defaultModel(sources))
.catch(gear.catch ? gear.catch : defaultCatch)
const state$ = (gear.model ? gear.model(actions) : defaultModel(actions))
.catch((err: any) => gear.catch ? gear.catch(err, actions) : defaultCatch(err, actions))
.shareReplay(1)

@@ -89,0 +89,0 @@ const views = teeth.reduce((accum, tooth) => Object.assign(accum, {

{
"name": "cycle-gear",
"version": "3.0.0",
"version": "3.1.0",
"description": "Main function factory for CycleJS",

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

@@ -32,2 +32,8 @@ # cycle-gear

The `catch` will handle the gear's `model` errors. While this could be manually
done for each gear model, as a top level part of a gear it encourages the ability
to handle errors systematically, such as how each `tooth` might deal with it. (It
also allows for a `catch` to be defaulted across a `transmission`, helping avoid
issues with a "stuck" `transmission`.)
## `pedal`

@@ -42,2 +48,2 @@

router such as [@cycle/history](https://github.com/cyclejs/history), and at lower levels a
`transmission` might be some other sort of user-action dependent state machine.
`transmission` might be some other sort of user-action dependent state machine.
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