Browse Source

Merge pull request #748 from tgallacher/fix/blog-react-v-16-3

Fix: added missing component instantiation within the 'forwardRef' AP…
main
Brian Vaughn 7 years ago
committed by GitHub
parent
commit
5ba8e04f26
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      examples/16-3-release-blog-post/forward-ref-example.js

4
examples/16-3-release-blog-post/forward-ref-example.js

@ -25,6 +25,10 @@ function withTheme(Component) {
));
}
// Here we assume that FancyButton has been imported into the current scope
const FancyThemedButton = withTheme(FancyButton);
// Create a ref using the new Referenace API, as above
// highlight-next-line
const fancyButtonRef = React.createRef();

Loading…
Cancel
Save