virtyaluk/mutation-watcher

View on GitHub

Showing 6 of 8 total issues

Function exports has 60 lines of code (exceeds 25 allowed). Consider refactoring.
Open

module.exports = function(grunt) {
    'use strict';

    grunt.initConfig({
        pkg: grunt.file.readJSON('package.json'),
Severity: Major
Found in Gruntfile.js - About 2 hrs to fix

    File MutationWatcher.js has 262 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    /**
     * @license
     * @author Bohdan Shtepan
     *
     * MutationWatcher 1.0.2
    Severity: Minor
    Found in MutationWatcher.js - About 2 hrs to fix

      Function _getConfig has 39 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

              _getConfig = function(target, opt) {
                  var that = this,
                      options = opt || { all: true, subtree: false },
                      toSet = {
                          elements: false,
      Severity: Minor
      Found in MutationWatcher.js - About 1 hr to fix

        Function _publisher has 37 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

                _publisher = function(mutationData) {
                    var that = this,
                        mutation = _getMutationData(mutationData),
                        cond;
        
        
        Severity: Minor
        Found in MutationWatcher.js - About 1 hr to fix

          Function _watch has 27 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

                  _watch = function(target, options) {
                      var that = this;
          
                      // Checks if there is observing that started earlier, if so - stops it
                      if (that._isObserving) {
          Severity: Minor
          Found in MutationWatcher.js - About 1 hr to fix

            Function _getMutationData has 26 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                    _getMutationData = function(mr) {
                        var md = {},
                            props = ['target', 'attributeName', 'attributeNameNamespace', 'oldValue', 'newValue',
                                'attributeChange', 'relatedNode', 'addedNodes', 'removedNodes', 'previousSibling', 'nextSibling', 'type'];
            
            
            Severity: Minor
            Found in MutationWatcher.js - About 1 hr to fix
              Severity
              Category
              Status
              Source
              Language