Detecting . Iphone10


Anybody has solution for iphone 10 ? My layout need slight changes for iphone X, so best would be to detect if it’s iphone 10 and add class to Page element maybe.
I’ve sound some solution, but this wirks only for current page, but i’m liiking for a solution, where i can have this .code in only one place, that will run for all pages.
For now i’m having almost 35 views, so quite pain to add this logic to every pages.
Thanks for help.