I used to make things that were comfortable for the screen resolution I was using as a novice, but as time went on and I started producing substantial stuff, I realised I needed to construct mobile-first features.
Of course, Chrome comes with a responsive view and a mobile view, but why do you need to preview in mobile? 🤔 🤔 🤔
Let say when trying to input something in text fields in mobile, keyboard will pop up, and sticky footer might cover up text fields, which we usually not observe in laptops.
Cases like above require to preview app in mobile before pushing into production.
So to preview in the Rails app in mobile follow the steps:
- Make sure your laptop and phone are connected
- Start sever in local with
rails s -p 3000 -b <IPv4 address of network>
- To get IPv4 address of the network connected
- Go to
settings > netwrok
- Run
ipconfig
in command line
- Go to
Top comments (0)