Showing 2,136 of 3,976 total issues
Function start
has 40 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
start: function() {
// If it’s already started, do nothing.
if ( STATE && STATE.start ) return P
Function _mouseDown
has 40 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
_mouseDown: function(event) {
// don't let more than one widget handle mouseStart
if ( mouseHandled ) {
return;
}
Function _attachments
has 40 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
_attachments: function(input, inst) {
var showOn, buttonText, buttonImage,
appendText = this._get(inst, "appendText"),
isRTL = this._get(inst, "isRTL");
Function load
has 40 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
load: function( index, event ) {
index = this._getIndex( index );
var that = this,
tab = this.tabs.eq( index ),
anchor = tab.find( ".ui-tabs-anchor" ),
Function ReportDispatcher
has a Cognitive Complexity of 13 (exceeds 5 allowed). Consider refactoring. Open
Open
getJasmineRequireObj().ReportDispatcher = function() {
function ReportDispatcher(methods) {
var dispatchedMethods = methods || [];
- 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 Any
has a Cognitive Complexity of 13 (exceeds 5 allowed). Consider refactoring. Open
Open
getJasmineRequireObj().Any = function(j$) {
function Any(expectedObject) {
if (typeof expectedObject === 'undefined') {
throw new TypeError(
- 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 toggleClass
has 39 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
toggleClass: function( value, stateVal ) {
var type = typeof value;
if ( typeof stateVal === "boolean" && type === "string" ) {
return stateVal ? this.addClass( value ) : this.removeClass( value );
Function access
has 39 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
var access = function( elems, fn, key, value, chainable, emptyGet, raw ) {
var i = 0,
len = elems.length,
bulk = key == null;
Function toggleClass
has 39 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
toggleClass: function( value, stateVal ) {
var type = typeof value;
if ( typeof stateVal === "boolean" && type === "string" ) {
return stateVal ? this.addClass( value ) : this.removeClass( value );
Function access
has 39 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
var access = function( elems, fn, key, value, chainable, emptyGet, raw ) {
var i = 0,
len = elems.length,
bulk = key == null;
Function specDone
has 39 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
proto.reportSpecResults = proto.specDone = function(spec) {
if(spec.results) { //jasmine 1.x
var specResult = spec.results()
if(specResult.skipped) {
this.skipped_or_pending_specs++;
Function compileNode
has 39 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
Op.prototype.compileNode = function(o) {
var answer, isChain, lhs, ref3, ref4, rhs;
isChain = this.isChainable() && this.first.isChainable();
if (!isChain) {
this.first.front = this.front;
Function access
has 39 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
var access = function( elems, fn, key, value, chainable, emptyGet, raw ) {
var i = 0,
length = elems.length,
bulk = key == null;
Function dayOfYearFromWeekInfo
has 39 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function dayOfYearFromWeekInfo(config) {
var w, weekYear, week, weekday, dow, doy, temp, weekdayOverflow;
w = config._w;
if (w.GG != null || w.W != null || w.E != null) {
Function QueryString
has 39 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
jasmineRequire.QueryString = function() {
function QueryString(options) {
this.navigateWithNewParam = function(key, value) {
options.getWindowLocation().search = this.fullStringWithNewParam(key, value);
Function close
has 39 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
close: function( event ) {
var tooltip,
that = this,
target = $( event ? event.currentTarget : this.element ),
tooltipData = this._find( target );
Function _respectSize
has 39 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
_respectSize: function( data ) {
var o = this._vBoundaries,
a = this.axis,
ismaxw = this._isNumber(data.width) && o.maxWidth && (o.maxWidth < data.width),
Function _optionDatepicker
has 39 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
_optionDatepicker: function(target, name, value) {
var settings, date, minDate, maxDate,
inst = this._getInst(target);
if (arguments.length === 2 && typeof name === "string") {
Function intersect
has 39 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
$.ui.intersect = (function() {
function isOverAxis( x, reference, size ) {
return ( x >= reference ) && ( x < ( reference + size ) );
}
Function _respectSize
has 39 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
_respectSize: function( data ) {
var o = this._vBoundaries,
a = this.axis,
ismaxw = this._isNumber(data.width) && o.maxWidth && (o.maxWidth < data.width),