title: Determine If An Element Is An Image Using Jquery In CKEditor
body: <p>I'm trying to determine if an element if an image or not using jQuery. This should be straightforward using <code>$('selector').is('img')</code>, but that's not working. Here is a screenshot from Chrome's watch expression console. I don't understand why the is() function is failing. The debugger says the element is an HTMLImageElement. Any suggestions?</p>
  
  <pre><code>var selectedElement = ckEditor.getSelection().getSelectedElement();
  var $element = $(selectedElement);
  var isImage = $element.is('img');
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/Y7rdw.png" alt="enter image description here"></p>