L3P3 / lui

Tiny, robust web framework in my taste.

Home Page:https://l3p3.de/dok/lui.html

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

New reducer format

L3P3 opened this issue · comments

commented

Instead of returning a dispatch method, return an object with methods for each action.

const [count, {increment}] = hook_model({
  init: () => 0,
  increment: n => n+1,
});

Both reducer hooks should be deprecated.

commented

Actually removed both old reducer hooks to save space.