2.0.0 • Published 5 years ago

@bgfist/weact-redux v2.0.0

Weekly downloads
2
License
MIT
Repository
-
Last release
5 years ago

Weact-Redux

Weact bindings for Redux

install

npm i @bgfist/weact-redux

Provider

import {Provider} from "@bgfist/weact-redux";
import store from ...

App(Provider(store)({
  onLoad(){},
  ...
}))

hook-style

import { useSelector, useActionCreator } from "@bgfist/weact-redux";

function Demo() {
  const age = useSelector(state=> state.age);
  const changeAgeAction = useActionCreator(changeAge);

  const onTapSomething = () => changeAgeAction(10);

  return {
    age,
    onTapSomething
  }
}
2.0.0

5 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago