We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2153a68 commit b9c9270Copy full SHA for b9c9270
components/dash-core-components/src/components/Clipboard.react.js
@@ -26,6 +26,15 @@ export default class Clipboard extends React.Component {
26
};
27
}
28
29
+ componentDidUpdate(prevProps) {
30
+ // If the data hasn't changed, do nothing.
31
+ if (!this.props.content || this.props.content === prevProps.content) {
32
+ return;
33
+ }
34
+ // If the data has changed, copy to clipboard
35
+ this.copyToClipboard();
36
37
+
38
// stringifies object ids used in pattern matching callbacks
39
stringifyId(id) {
40
if (typeof id !== 'object') {
0 commit comments