rofrischmann/inline-style-prefixer

View on GitHub

Showing 161 of 397 total issues

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

function prefixValue(value, propertyPrefixMap) {
  if (isPrefixedValue(value)) {
    return value
  }

Severity: Minor
Found in modules/plugins/transition.js - About 1 hr to fix

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

    function createPrefixer(_ref) {
      var prefixMap = _ref.prefixMap,
          plugins = _ref.plugins;
    
      function prefixAll(style) {
    Severity: Minor
    Found in benchmark/packages/302/static/createPrefixer.js - About 1 hr to fix

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

      function createPrefixer(_ref) {
        var prefixMap = _ref.prefixMap,
            plugins = _ref.plugins;
      
        function prefixAll(style) {
      Severity: Minor
      Found in benchmark/packages/301/static/createPrefixer.js - About 1 hr to fix

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

              value: function _prefixStyle(style) {
                for (var property in style) {
                  var value = style[property];
        
                  // handle nested objects
        Severity: Minor
        Found in benchmark/packages/300/dynamic/createPrefixer.js - About 1 hr to fix

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

            function Prefixer() {
              var _this = this;
          
              var options = arguments.length <= 0 || arguments[0] === undefined ? {} : arguments[0];
          
          
          Severity: Minor
          Found in benchmark/packages/205/Prefixer.js - About 1 hr to fix

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

            export function generateFile(prefixMap, pluginList, compatibility) {
              const pluginImports = pluginList
                .map((plugin) => generateImportString(plugin, compatibility))
                .join('\n')
            
            
            Severity: Minor
            Found in modules/generator/index.js - About 1 hr to fix

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

              function createPrefixer(_ref) {
                var prefixMap = _ref.prefixMap,
                    plugins = _ref.plugins;
              
                return function prefix(style) {
              Severity: Minor
              Found in benchmark/packages/700/createPrefixer.js - About 1 hr to fix

                Function getPrefixedKeyframes has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
                Open

                function getPrefixedKeyframes(browserName, browserVersion, cssPrefix) {
                  var prefixedKeyframes = 'keyframes';
                
                  if (browserName === 'chrome' && browserVersion < 43 || (browserName === 'safari' || browserName === 'ios_saf') && browserVersion < 9 || browserName === 'opera' && browserVersion < 30 || browserName === 'android' && browserVersion <= 4.4 || browserName === 'and_uc') {
                    return cssPrefix + prefixedKeyframes;
                Severity: Minor
                Found in benchmark/packages/300/utils/getPrefixedKeyframes.js - About 55 mins to fix

                Cognitive Complexity

                Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                A method's cognitive complexity is based on a few simple rules:

                • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                • Code is considered more complex for each "break in the linear flow of the code"
                • Code is considered more complex when "flow breaking structures are nested"

                Further reading

                Function getPrefixedKeyframes has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
                Open

                function getPrefixedKeyframes(browserName, browserVersion, cssPrefix) {
                  var prefixedKeyframes = 'keyframes';
                
                  if (browserName === 'chrome' && browserVersion < 43 || (browserName === 'safari' || browserName === 'ios_saf') && browserVersion < 9 || browserName === 'opera' && browserVersion < 30 || browserName === 'android' && browserVersion <= 4.4 || browserName === 'and_uc') {
                    return cssPrefix + prefixedKeyframes;
                Severity: Minor
                Found in benchmark/packages/301/utils/getPrefixedKeyframes.js - About 55 mins to fix

                Cognitive Complexity

                Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                A method's cognitive complexity is based on a few simple rules:

                • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                • Code is considered more complex for each "break in the linear flow of the code"
                • Code is considered more complex when "flow breaking structures are nested"

                Further reading

                Function transition has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
                Open

                function transition(property, value, style, _ref) {
                  var cssPrefix = _ref.cssPrefix,
                      keepUnprefixed = _ref.keepUnprefixed,
                      requiresPrefix = _ref.requiresPrefix;
                
                
                Severity: Minor
                Found in benchmark/packages/301/dynamic/plugins/transition.js - About 55 mins to fix

                Cognitive Complexity

                Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                A method's cognitive complexity is based on a few simple rules:

                • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                • Code is considered more complex for each "break in the linear flow of the code"
                • Code is considered more complex when "flow breaking structures are nested"

                Further reading

                Function transition has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
                Open

                function transition(property, value, style, _ref) {
                  var cssPrefix = _ref.cssPrefix,
                      keepUnprefixed = _ref.keepUnprefixed,
                      requiresPrefix = _ref.requiresPrefix;
                
                
                Severity: Minor
                Found in benchmark/packages/302/dynamic/plugins/transition.js - About 55 mins to fix

                Cognitive Complexity

                Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                A method's cognitive complexity is based on a few simple rules:

                • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                • Code is considered more complex for each "break in the linear flow of the code"
                • Code is considered more complex when "flow breaking structures are nested"

                Further reading

                Function transition has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
                Open

                function transition(property, value, style, _ref) {
                  var cssPrefix = _ref.cssPrefix,
                      keepUnprefixed = _ref.keepUnprefixed,
                      requiresPrefix = _ref.requiresPrefix;
                
                
                Severity: Minor
                Found in benchmark/packages/300/dynamic/plugins/transition.js - About 55 mins to fix

                Cognitive Complexity

                Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                A method's cognitive complexity is based on a few simple rules:

                • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                • Code is considered more complex for each "break in the linear flow of the code"
                • Code is considered more complex when "flow breaking structures are nested"

                Further reading

                Function getPrefixedKeyframes has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
                Open

                function getPrefixedKeyframes(browserName, browserVersion, cssPrefix) {
                  var prefixedKeyframes = 'keyframes';
                
                  if (browserName === 'chrome' && browserVersion < 43 || (browserName === 'safari' || browserName === 'ios_saf') && browserVersion < 9 || browserName === 'opera' && browserVersion < 30 || browserName === 'android' && browserVersion <= 4.4 || browserName === 'and_uc') {
                    return cssPrefix + prefixedKeyframes;
                Severity: Minor
                Found in benchmark/packages/302/utils/getPrefixedKeyframes.js - About 55 mins to fix

                Cognitive Complexity

                Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                A method's cognitive complexity is based on a few simple rules:

                • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                • Code is considered more complex for each "break in the linear flow of the code"
                • Code is considered more complex when "flow breaking structures are nested"

                Further reading

                Function default has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
                Open

                exports.default = function (_ref) {
                  var browser = _ref.browser;
                  var version = _ref.version;
                  var prefix = _ref.prefix;
                
                
                Severity: Minor
                Found in benchmark/packages/205/utils/getPrefixedKeyframes.js - About 55 mins to fix

                Cognitive Complexity

                Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                A method's cognitive complexity is based on a few simple rules:

                • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                • Code is considered more complex for each "break in the linear flow of the code"
                • Code is considered more complex when "flow breaking structures are nested"

                Further reading

                Function calc has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                Open

                function calc(_ref) {
                  var property = _ref.property;
                  var value = _ref.value;
                  var _ref$browserInfo = _ref.browserInfo;
                  var browser = _ref$browserInfo.browser;
                Severity: Minor
                Found in benchmark/packages/205/plugins/calc.js - About 45 mins to fix

                Cognitive Complexity

                Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                A method's cognitive complexity is based on a few simple rules:

                • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                • Code is considered more complex for each "break in the linear flow of the code"
                • Code is considered more complex when "flow breaking structures are nested"

                Further reading

                Function calc has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                Open

                function calc(property, value, style, _ref) {
                  var browserName = _ref.browserName,
                      browserVersion = _ref.browserVersion,
                      cssPrefix = _ref.cssPrefix,
                      keepUnprefixed = _ref.keepUnprefixed;
                Severity: Minor
                Found in benchmark/packages/300/dynamic/plugins/calc.js - About 45 mins to fix

                Cognitive Complexity

                Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                A method's cognitive complexity is based on a few simple rules:

                • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                • Code is considered more complex for each "break in the linear flow of the code"
                • Code is considered more complex when "flow breaking structures are nested"

                Further reading

                Avoid deeply nested control flow statements.
                Open

                          if (!prefixMap[property]) {
                            prefixMap[property] = [];
                          }
                Severity: Major
                Found in benchmark/packages/700/generator/generatePrefixMap.js - About 45 mins to fix

                  Function calc has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                  Open

                  function calc(property, value, style, _ref) {
                    var browserName = _ref.browserName,
                        browserVersion = _ref.browserVersion,
                        cssPrefix = _ref.cssPrefix,
                        keepUnprefixed = _ref.keepUnprefixed;
                  Severity: Minor
                  Found in benchmark/packages/301/dynamic/plugins/calc.js - About 45 mins to fix

                  Cognitive Complexity

                  Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                  A method's cognitive complexity is based on a few simple rules:

                  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                  • Code is considered more complex for each "break in the linear flow of the code"
                  • Code is considered more complex when "flow breaking structures are nested"

                  Further reading

                  Function zoomCursor has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                  Open

                  function zoomCursor(_ref) {
                    var property = _ref.property;
                    var value = _ref.value;
                    var _ref$browserInfo = _ref.browserInfo;
                    var browser = _ref$browserInfo.browser;
                  Severity: Minor
                  Found in benchmark/packages/205/plugins/zoomCursor.js - About 45 mins to fix

                  Cognitive Complexity

                  Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                  A method's cognitive complexity is based on a few simple rules:

                  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                  • Code is considered more complex for each "break in the linear flow of the code"
                  • Code is considered more complex when "flow breaking structures are nested"

                  Further reading

                  Avoid deeply nested control flow statements.
                  Open

                            if (versions[browser].x >= browserList[browser]) {
                              const property = keywordProperties[i]
                  
                              if (!prefixMap[property]) {
                                prefixMap[property] = []
                  Severity: Major
                  Found in modules/generator/generatePrefixMap.js - About 45 mins to fix
                    Severity
                    Category
                    Status
                    Source
                    Language