title: How to programmatically detect iPhone XS or iPhone X?
body: <p>One of my apps connects to a web app service that delivers device specific news to to the user. To adapt this to the latest iPhone versions I need to programmatically distinguish between the iPhone XS and iPhone X. How can this be done?</p>
  
  <p><code>[[UIScreen mainScreen] bounds].size</code> was always a good starting point to tell the different devices apart. However, iPhone XS and iPhone X have the same screen dimensions: 1125 x 2436. Thus using <code>[[UIScreen mainScreen] bounds].size</code> does not work in this case.</p>
  
  <p>Is there any other method to detect the latest iPhone versions?</p>
  
  <p><strong>EDIT:</strong>
  This is <strong>NOT a duplicate</strong> of the question "How to detected iPhone X" since all answers/solutions discussed there use the screen dimensions to specify the device type. As described above iPhone X and iPhone XS have the exact same dimensions and thus the solutions cannot tell these two apart... </p>