Google website web.dev suggests to always set html to 100% width, this (they say) will automatically set your html to your viewport width.
For the height I imagine it is the same, but why fixing the height of a webpage if the common user experience is to scroll down in order to find more content?
If you set your html, then your body should just inherit those properties I think. There are some cases where that does not happen.
In this web page of Codeacademy Forum for example we can see that body is inheriting from html the following props:
The html height is set to 100%, but the body is not inheriting it. The body instead was set to min-height: 100%.
If the parent size is set and if the children occupy less space you’ll be left with empty space, not very nice in my opinion.
If the parent size is set and if the children occupy more space, then the parent will either cut out the extra content or let it show, this depends from the property
Finally if the parent size is not set whatever space the children occupy the parent will adapt.