@jsenv/navi 0.18.24 → 0.18.25

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1248,7 +1248,11 @@ ${lines.join("\n")}`);
1248
1248
  for (const actionToReset of willResetSet) {
1249
1249
  const actionToResetPrivateProperties =
1250
1250
  getActionPrivateProperties(actionToReset);
1251
- actionToResetPrivateProperties.performReset({ reason });
1251
+ actionToResetPrivateProperties.performReset({
1252
+ reason,
1253
+ willRunOrPrerun:
1254
+ willRunSet.has(actionToReset) || willPrerunSet.has(actionToReset),
1255
+ });
1252
1256
  activationWeakSet.delete(actionToReset);
1253
1257
  }
1254
1258
  }
@@ -1897,7 +1901,7 @@ const createAction = (callback, rootOptions = {}) => {
1897
1901
  }
1898
1902
  };
1899
1903
 
1900
- const performReset = ({ reason }) => {
1904
+ const performReset = ({ reason, willRunOrPrerun }) => {
1901
1905
  abort(reason);
1902
1906
  if (DEBUG$3) {
1903
1907
  console.log(`"${action}": resetting (reason: ${reason})`);
@@ -1913,11 +1917,11 @@ const createAction = (callback, rootOptions = {}) => {
1913
1917
  actionPromiseMap.delete(action);
1914
1918
  batch(() => {
1915
1919
  errorSignal.value = null;
1916
- if (!keepOldData) {
1920
+ if (!keepOldData && !willRunOrPrerun) {
1917
1921
  valueSignal.value = valueInitial;
1918
- }
1919
- if (outputSignal) {
1920
- outputSignal.value = undefined;
1922
+ if (outputSignal) {
1923
+ outputSignal.value = undefined;
1924
+ }
1921
1925
  }
1922
1926
  isPrerunSignal.value = true;
1923
1927
  runningStateSignal.value = IDLE;
@@ -2319,7 +2323,7 @@ getActionPrivateProperties(COMPLETED_ACTION).performRun({});
2319
2323
  const actionRunEffect = (
2320
2324
  action,
2321
2325
  deriveActionParamsFromSignals,
2322
- { debounce, meta } = {},
2326
+ { debounce, actionOptions } = {},
2323
2327
  ) => {
2324
2328
  if (typeof action === "function") action = createAction(action);
2325
2329
  let lastTruthyParams;
@@ -2389,7 +2393,7 @@ const actionRunEffect = (
2389
2393
  }
2390
2394
  }
2391
2395
  },
2392
- meta,
2396
+ ...actionOptions,
2393
2397
  });
2394
2398
  if (actionParamsSignal.peek()) {
2395
2399
  actionRunnedByThisEffect.run({ reason: "initial truthy params" });