Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

AngularJS material mobile layout not responsive

I am trying to make a responsive website and the issue that I am having is the mobile version just looks like a super tiny version of the desktop.

<body ng-controller="body" >

<div layout="column">
    <div flex>
        I'm above on mobile, and to the left on larger devices.
    </div>
    <div flex>
        I'm below on mobile, and to the right on larger devices.
    </div>
</div>
</body>

The example above on a desktop has the two flex divs next to each other in a row, if i re-size the browser the divs eventually go from inline to one under the other just like it supposed to. The problem is that on a mobile the divs stay inline and the font looks tiny and it basically just looks like a full very tiny website. It doesn't seem like the responsive part is kicking in. I am clearly missing something.

like image 633
americanslon Avatar asked Sep 27 '26 17:09

americanslon


1 Answers

You need viewport meta in head tag. Please reference:https://developer.mozilla.org/en-US/docs/Mozilla/Mobile/Viewport_meta_tag

like image 196
Nicol Avatar answered Sep 30 '26 07:09

Nicol



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!