Skip to main content

21 docs tagged with "Hook"

View all tags

Best Practices

如果将一个函数任意地将其放在 useEffect Deps List 中

Context

- Create custom XXXContextProvider:

Hooks

React Hooks allow you to use state and other React features in functional components.

Internals

- Reuse stateful logic between components

Memo

- Returns a memoized value.

Reducer

- Use useState whenever manage a JS primitive (e.g. string, boolean, integer).

State

- Read rendered props/state.