title: Reconnect and disconnect a MutationObserver
body: <p>This question is the sequel of <a href="https://stackoverflow.com/questions/35097520/mutationobserver-for-class-not-for-id">this</a> one. However, it is not necessary to read the previous, I'm just giving a link for interested readers.</p>
  
  <p>There is an observer, which will react on every element with some class, as @Shomz suggested:</p>
  
  <pre><code>var target = document.querySelectorAll(".someclass");
  for (var i = 0; i &lt; target.length; i++) {
      create(target[i]);
  }
  
  function create(t) {
      var observer = new MutationObserver(function(mutations) {
          mutations.forEach(function(mutation) {
              var foo = t.getAttribute("aaa")
              if (foo == "vvv")
                  t.style.backgroundColor = "red";
          });
      });
  
      var config = {
          attributes: true
      };
  
      observer.observe(t, config);
  }
  </code></pre>
  
  <p>So, there are two closely intertwined questions.</p>
  
  <p>1) For some reasons, the observer may be disconnected. How I can reconnect it? I tried to use <code>observer.observe</code>, but it doesn't work here.</p>
  
  <p>2) And the second question, what is the way to manually disconnect an observer? I tried to use <code>observer.disconnect();</code>, but it is also doesn't work.</p>