Question: I want to declare default props in a functional component 

normally we would do this

```js
function Body() {
    static defaultProps = {
        counter: 0
    }
    return (
        <div>
            body
        </div>
    );
}

```

this obviously doesn't work

Answer: 
```js
function Body({counter=0}) {
    return (
        <div>
            body
        </div>
    );
}

```

counter now has initial value of 0
You can declare defaultProps outside the functional component. In your case it would be something like this - 

```
   function Body(props) {
    return (
        <div>
            {props.counter}
        </div>
    );
  }
  Body.defaultProps = {
      counter: 0
  }

```