i have unknown number of card i want to ngfor on them and display every two card in one row
<mat-card class="example-card">
<mat-card-header>
<div mat-card-avatar class="example-header-image"></div>
<mat-card-title>{{user.firstName}}</mat-card-title>
<mat-card-subtitle>{{user.lastName}}</mat-card-subtitle>
</mat-card-header>
<mat-card-content>
<p>
The Shiba Inu is the smallest of the six original and distinct spitz breeds of dog from Japan.
A small, agile dog that copes very well with mountainous terrain, the Shiba Inu was originally
bred for hunting.
</p>
</mat-card-content>
<mat-card-actions>
</mat-card-actions>
</mat-card>
i'm using angular 5 and material design 6 is there anyway to do that ?
Spent hours on this... turned out to be trivial: simply add float:left to your class CSS. In my case it looked like this:
.example-card {
max-width: 300px;
margin-bottom: 50px;
float: left;
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With