GT2/GT2-iOS/node_modules/react-deep-force-update
Ren Ren Juan 30eef7d036 correct tree err 2018-02-12 17:26:06 +00:00
..
lib correct tree err 2018-02-12 17:26:06 +00:00
src correct tree err 2018-02-12 17:26:06 +00:00
LICENSE.md correct tree err 2018-02-12 17:26:06 +00:00
README.md correct tree err 2018-02-12 17:26:06 +00:00
package.json correct tree err 2018-02-12 17:26:06 +00:00

README.md

react-deep-force-update

build status npm version npm downloads

Force-updates React component tree recursively.

Dont use this in your application code!

Youll only need this if youre writing a React development tool or library like React Proxy and you want to enforce a deep update regardless of what component classes have to say.

Installation

npm install --save react-deep-force-update

Requires React 0.13 and newer.

Usage

import React from 'react'; // or 'react-native'
import getDeepForceUpdate from 'react-deep-force-update';

const deepForceUpdate = getDeepForceUpdate(React);
const instance = React.render(<Something />);

// Will force-update the whole rendered tree
// even if components in the middle of it
// define a strict shouldComponentUpdate().
deepForceUpdate(instance);

Credits

This project is based on the code written by @syranide.

License

MIT