One of the main principles that now helps you get a good night's sleep is to avoid gadgets before bed.