Actually you can't do that, you have to get the children object from props, just as you said:
const PapeContainer = ({children}) => {
return (
<div //some classes and other stuff>
{children}
</div>
);
}
I think that what that comment wanted to say is that you don't have to pass children as a specific prop named "children" in your parent component, like this:
<PapeContainer //some classes and other stuff
children={someChildren}
/>
That would not make sense because "children" is a special property of React which contains any child elements defined within the component. So instead of passing the prop explicitly you put the children content inside the parent tag, like this:
<PapeContainer //some classes and other stuff>
{someChildren}
/>
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…