title: Is there a way to know if a range is a named range?
body: <p>Context: I am working on a Addin for Excel using Microsoft's "new" Office Javascript API.</p>
  
  <p>So far, I am able to get the user's selection and a collection of named ranges in the worksheet with the code below:</p>
  
  <pre><code>const selectedRange = context.workbook.getSelectedRange();
  const namedRanges = context.workbook.names;
  </code></pre>
  
  <p>However, what I am trying to achieve is to check if the user's selection <code>selectedRange</code> is a named range in the worksheet and if so get that named range object.</p>
  
  <p>I have not found any "built-in" way to do this so far and the only ideas I have would be a nightmare to implement or result in bad performance.</p>
  
  <p>Is this even possible? What are your ideas?</p>
  
  <p>Thank you for reading!</p>