Using Ionic 3 Framework and components, attributes, properties only (no media queries if possible), does someone know how to define a responsive grid based on screen-orientation? I want the layout to be displayed in one column when screen-orientation is "portrait" and in two columns when screen-orientation is "landscape", no matter what the screen size is.
I did it using the showWhen attribute like below but it makes me duplicate the code contained in each <ion-col>.
Is there any better solution?
<ion-grid>
<ion-row>
<ion-col showWhen="portrait" col-12>
...[content_1]...
</ion-col>
<ion-col showWhen="landscape" col-6 push-6>
...[content_1]...
</ion-col>
<ion-col showWhen="portrait" col-12>
...[content_2]...
</ion-col>
<ion-col showWhen="landscape" col-6 push-6>
...[content_2]...
</ion-col>
</ion-row>
</ion-grid>