mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-05-01 02:42:47 +08:00
13 lines
358 B
TypeScript
13 lines
358 B
TypeScript
import * as React from 'react';
|
|
import shallowCompare = require('react-addons-shallow-compare');
|
|
|
|
export class MyComponent extends React.Component {
|
|
shouldComponentUpdate(nextProps: any, nextState: any, nextContext: any): boolean {
|
|
return shallowCompare(this, nextProps, nextState);
|
|
}
|
|
|
|
render() {
|
|
return <div>empty</div>;
|
|
}
|
|
}
|