How to adapt to the ionic1 mobile screen?

for special reasons, this project still uses ionic1 for programming, how to adapt to various sizes of mobile phone screens, using em or rem?
if it is a more advanced version of ionic, does it have its own way to adapt?

Mar.10,2021

No, so you have to write the adaptation function yourself. It is recommended to use vw for adaptation. The code on the scss side is as follows: enter the width and height in the design draft, you can directly calculate the width and height on the real machine. Suppose the width of the design draft is 720; you can take a look at my small project: hw-basic

$screen_width=720;
@function rem(width){
@return (width/$screen_width)*100vw
}

Menu