title: Js-jQuery - check if element is focused or get last focused element class
body: <p>is it possible to check if an element is focused?</p>
  
  <p>i tryed:</p>
  
  <pre><code> &lt;a href="#"&gt;&lt;/a&gt;
      $('a').is(':focused');
  </code></pre>
  
  <p>but it won't work.</p>
  
  <p>Also i would like to understand if is possible to get the last focused document element attr class:</p>
  
  <pre><code>var last_focused_class = document.lastFocusedElement.class;
  </code></pre>
  
  <p>for example</p>