Use Default Props React

Tell us what’s happening:

This is the code that’s working but my problem is WHY is it rendering on the page when there is no render() method.

Thank you for your answers.

Your code so far


const ShoppingCart = (props) => {
  return (
    <div>
      <h1>Shopping Cart Component</h1>
    </div>
  )
};
// change code below this line

ShoppingCart.defaultProps = {
  items: 0
}

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.102 Safari/537.36.

Link to the challenge: