How to use the @material-ui/utils.refType.isRequired function in @material-ui/utils

To help you get started, we’ve selected a few @material-ui/utils examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github mui-org / material-ui / packages / material-ui / src / RootRef / RootRef.js View on Github external
}

  render() {
    return this.props.children;
  }
}

RootRef.propTypes = {
  /**
   * The wrapped element.
   */
  children: PropTypes.element.isRequired,
  /**
   * A ref that points to the first DOM node of the wrapped element.
   */
  rootRef: refType.isRequired,
};

if (process.env.NODE_ENV !== 'production') {
  RootRef.propTypes = exactProp(RootRef.propTypes);
}

export default RootRef;