Comparing version 2.0.20 to 2.0.21
@@ -123,7 +123,13 @@ // Minimum TypeScript Version: 4.2 | ||
// An effecter is the function that runs an effect. | ||
type Effecter<S, P = any> = ( | ||
dispatch: Dispatch<S>, | ||
payload: P | ||
) => void | Promise<void> | ||
// An effect is where side effects and any additional dispatching may occur. | ||
type Effect<S, P = any> = readonly [ | ||
effecter: (dispatch: Dispatch<S>, payload: P) => void | Promise<void>, | ||
payload: P | ||
] | ||
type Effect<S, P = any> = | ||
| Effecter<S, P> | ||
| readonly [effecter: Effecter<S, P>, payload: P] | ||
@@ -130,0 +136,0 @@ // Effects can be declared conditionally. |
@@ -412,3 +412,3 @@ var SSR_NODE = 1 | ||
.map( | ||
(fx) => fx && fx !== true && fx[0](dispatch, fx[1]), | ||
(fx) => fx && fx !== true && (fx[0] || fx)(dispatch, fx[1]), | ||
update(action[0]) | ||
@@ -415,0 +415,0 @@ ) |
{ | ||
"name": "hyperapp", | ||
"version": "2.0.20", | ||
"version": "2.0.21", | ||
"type": "module", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
27328
568