2.7.1 • Published 3 years ago

@wbe/use-did-update v2.7.1

Weekly downloads
266
License
MIT
Repository
github
Last release
3 years ago

@wbe/use-did-update

Execute effect only when state or props is updated.

npm.io npm.io npm.io npm.io

Installation

$ npm install -s @wbe/use-did-update

How to use

import { UseDidUpdate } from "@wbe/use-did-update";

example

const App = ({ count }) => {
  useDidUpdate(() => {
    console.log("Will be called only if count props change");
  }, [count]);
};

Parameters / Props

paramstypedescriptiondefault value
effect()=> voideffect to execute/
dependenciesany[]dependencies array of argument(s) allowing to re-suscribre to the effect/

Returns

void

2.7.1

3 years ago

2.7.0

3 years ago

2.4.0

4 years ago

2.3.0

4 years ago

2.2.0-alpha.0

4 years ago

2.1.0

4 years ago

2.0.0

4 years ago

2.0.0-alpha.11

4 years ago

2.0.0-alpha.10

4 years ago

2.0.0-alpha.7

4 years ago

2.0.0-alpha.6

4 years ago

2.0.0-alpha.3

4 years ago

2.0.0-alpha.0

4 years ago

2.0.0-alpha.1

4 years ago

2.0.0-alpha.2

4 years ago

1.6.0

4 years ago

1.5.0

4 years ago

1.4.2

5 years ago

1.4.2-alpha.0

5 years ago

1.4.1

5 years ago