Check out example codes for "why there's a default margin in html <body>". It will help you in understanding the concepts better.

Code Example 1

body {
  margin: 0px;
  padding: 0px;
  ...
}

Learn ReactJs, React Native from akashmittal.com