Answered by Sayyidi Habib Umar bin Hafiz (may Allah protect him and benefit us by him)
How do we raise our children in an open society in which they have access to mobile devices?
Firstly we should plant veneration and vigilance of Allah in their hearts through talking to them, spending time with them and taking them to attend gatherings of knowledge and remembrance. We should also tell them about the people of the past who had fear of Allah and show them videos and talks by scholars that will increase their fear of Allah.
We should put some restrictions on their use of these devices and upon their interaction with society so that they learn to take that which is of benefit and leave that which is not.