Reputation: 1426
I have started a default Angular 5 CLI app...
ng new testApp
I then changed the background app.component.html to gray so you can see my issue...
<div style="text-align:center; background:gray">
The default app always has these unnecessary gaps (margins? padding?) between the browser's edge and the first level of content (container?). What is the easiest, most direct way to remove these gaps completely? There should be a single value I can change somewhere to fix this, right?
Upvotes: 0
Views: 1411
Reputation: 341
Use in app.component.scss
::ng-deep * {
margin: 0;
padding: 0;
}
Upvotes: 0
Reputation: 26
This space is the margin of the body and the margin of
<h1> Welcome to app! </h1>
Upvotes: 1