Showing 27 of 82 total issues
File script.js
has 344 lines of code (exceeds 250 allowed). Consider refactoring. Open
/**
* This component made by Sagalbot
*
* https://github.com/sagalbot/vue-select
*/
Function updateTypeFilter
has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring. Open
updateTypeFilter(val) {
this.clearFilter();
if (val) {
const re = /^(.*) \((.*)\)/;
- 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 getJSON
has a Cognitive Complexity of 19 (exceeds 5 allowed). Consider refactoring. Open
export default function getJSON (url, header = []) {
const request = new window.XMLHttpRequest()
const data = {}
// p (-simulated- promise)
const p = {
- 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
`` has 23 functions (exceeds 20 allowed). Consider refactoring. Open
methods: {
close () {
this.displayDayView = this.displayMonthView = this.displayYearView = false
},
inputClick () {
File script.js
has 267 lines of code (exceeds 250 allowed). Consider refactoring. Open
import translations from '../_texts/translations.js'
export default {
props: {
value: { type: String },
Function setItems
has a Cognitive Complexity of 17 (exceeds 5 allowed). Consider refactoring. Open
setItems (data) {
if (this.async) {
this.items = this.asyncKey ? data[this.asyncKey] : data
this.items = this.items.slice(0, this.limit)
} else {
- 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 transition
has a Cognitive Complexity of 16 (exceeds 5 allowed). Consider refactoring. Open
transition (val, old) {
if (val === old) { return }
const el = this.$el
const body = document.body
if (val) {
- 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 FetcherData
has 61 lines of code (exceeds 40 allowed). Consider refactoring. Open
const FetcherData = Entity => (opts = {}, headers = {}) => {
const tenant = tenantMananger.get();
const k = _.get(Entity, "ename");
const cache_key = _.get(opts, "cache_key", "d");
const { path } = opts;
Function data
has 56 lines of code (exceeds 40 allowed). Consider refactoring. Open
data() {
return {
limit: 300,
results: {
servers: {
Function beforeDestroy
has a Cognitive Complexity of 13 (exceeds 5 allowed). Consider refactoring. Open
beforeDestroy () {
if (this._tabGroup) {
this._tabGroup.tabs = this._tabGroup.tabs.filter(el => el !== this)
}
if (this._tabs) {
- 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 data
has 50 lines of code (exceeds 40 allowed). Consider refactoring. Open
data() {
const initData = {
name: null,
method: "GET",
endpoint: null,
Function getJSON
has 47 lines of code (exceeds 40 allowed). Consider refactoring. Open
export default function getJSON (url, header = []) {
const request = new window.XMLHttpRequest()
const data = {}
// p (-simulated- promise)
const p = {
Function data
has 46 lines of code (exceeds 40 allowed). Consider refactoring. Open
data() {
return {
cdb: 0,
family: "Database",
foptions: "Oracle",
Function data
has 45 lines of code (exceeds 40 allowed). Consider refactoring. Open
data: function() {
return {
entity: new Servers(),
columns: [
"name",
Function created
has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring. Open
created () {
this._isTab = true
let tabs = this
while (!this._tabs && tabs.$parent) {
if (tabs._isTabGroup) {
- 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 data
has 41 lines of code (exceeds 40 allowed). Consider refactoring. Open
data: function() {
return {
model: {},
entity: Reports,
options: {
Function action
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
action (val, p) {
if (this.sem) {
if (val === null) { return }
this.sem = false
if (val && this.callback instanceof Function) this.callback()
- 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 toggleDropdown
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
toggleDropdown (e) {
if (e.target === this.$refs.openIndicator || e.target === this.$refs.search || e.target === this.$refs.toggle || e.target === this.$el) {
if (this.open) {
this.$refs.search.blur() // dropdown will close on blur
} else {
- 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 select
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
select (option) {
if (this.isOptionSelected(option)) {
this.deselect(option)
} else {
if (this.taggable && !this.optionExists(option)) {
- 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 show
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
show (options) {
if (options) {
if (options.text) { this.text = options.text }
if (options.size) { this.size = options.size }
if (options.fixed) { this.fixed = options.fixed }
- 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"