Showing 1,331 of 3,238 total issues
File sizzle.js
has 1467 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/*!
* Sizzle CSS Selector Engine v2.3.3
* https://sizzlejs.com/
*
* Copyright jQuery Foundation and other contributors
Function diff
has 732 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
QUnit.diff = ( function() {
function DiffMatchPatch() {
}
// DIFF FUNCTIONS
File qunit.js
has 1320 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/**
* QUnit v1.5.0 - A JavaScript Unit Testing Framework
*
* http://docs.jquery.com/QUnit
*
File options.js
has 1206 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
module('Options', {
setup: function(){},
teardown: function(){
$('#qunit-fixture *').each(function(){
var t = $(this);
File qunit.js
has 964 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/*
* QUnit - A JavaScript Unit Testing Framework
*
* http://docs.jquery.com/QUnit
*
Function exports
has 428 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
module.exports = function (grunt) {
'use strict';
// Force use of Unix newlines
grunt.util.linefeed = '\n';
Function processRelativeTime
has a Cognitive Complexity of 96 (exceeds 5 allowed). Consider refactoring. Open
Open
function processRelativeTime(number, withoutSuffix, key, isFuture) {
var result = number + ' ';
switch (key) {
case 's':
return withoutSuffix || isFuture ? 'nekaj sekund' : 'nekaj sekundami';
- Read upRead up
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 expander
has 284 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
$.fn.expander = function(options) {
var meth = 'init';
if (typeof options === 'string') {
meth = options;
Function ajax
has 251 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
ajax: function( url, options ) {
// If url is an object, simulate pre-1.5 signature
if ( typeof url === "object" ) {
options = url;
Function ajax
has 251 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
ajax: function( url, options ) {
// If url is an object, simulate pre-1.5 signature
if ( typeof url === "object" ) {
options = url;
Function setDocument
has 245 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
setDocument = Sizzle.setDocument = function( node ) {
var hasCompare, subWindow,
doc = node ? node.ownerDocument || node : preferredDoc;
// Return early if doc is invalid or already selected
Function setDocument
has 245 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
setDocument = Sizzle.setDocument = function( node ) {
var hasCompare, subWindow,
doc = node ? node.ownerDocument || node : preferredDoc;
// Return early if doc is invalid or already selected
Function setDocument
has 245 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
setDocument = Sizzle.setDocument = function( node ) {
var hasCompare, subWindow,
doc = node ? node.ownerDocument || node : preferredDoc;
// Return early if doc is invalid or already selected
Function ajax
has 240 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
ajax: function( url, options ) {
// If url is an object, simulate pre-1.5 signature
if ( typeof url === "object" ) {
options = url;
Function exports
has 232 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
module.exports = function(grunt){
'use strict';
// Force use of Unix newlines
grunt.util.linefeed = '\n';
Function translate
has a Cognitive Complexity of 57 (exceeds 5 allowed). Consider refactoring. Open
Open
function translate(number, withoutSuffix, key, isFuture) {
var result = number + ' ';
switch (key) {
case 's':
return withoutSuffix || isFuture ? 'nokkrar sekúndur' : 'nokkrum sekúndum';
- Read upRead up
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
File effects.js
has 535 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
define( [
"./core",
"./var/document",
"./var/rcssNum",
"./var/rnothtmlwhite",
Function setDocument
has 218 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
setDocument = Sizzle.setDocument = function( node ) {
var hasCompare, parent,
doc = node ? node.ownerDocument || node : preferredDoc;
// If no document and documentElement is available, return
File event.js
has 519 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
define( [
"./core",
"./var/document",
"./var/documentElement",
"./var/rnothtmlwhite",
Function dump
has 210 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
QUnit.dump = (function() {
function quote( str ) {
return "\"" + str.toString().replace( /\\/g, "\\\\" ).replace( /"/g, "\\\"" ) + "\"";
}
function literal( o ) {