Showing 580 of 800 total issues
Avoid too many return
statements within this function. Open
return ["getUserIdentity"];
Avoid too many return
statements within this function. Open
return segments;
Avoid too many return
statements within this function. Open
return `~${versionWanted}`;
Avoid too many return
statements within this function. Open
return { [operatorMap[operator]]: value };
Avoid too many return
statements within this function. Open
return { notBetween: { lower: value[0], upper: value[1] } };
Avoid too many return
statements within this function. Open
return ["useForgotPassword"];
Avoid too many return
statements within this function. Open
return `${versionInPackageJson}`;
Avoid too many return
statements within this function. Open
return { like: `${value}%` };
Avoid too many return
statements within this function. Open
return { notILike: `%${value}` };
Avoid too many return
statements within this function. Open
return {};
Function CreateButton
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
export const CreateButton: React.FC<CreateButtonProps> = ({
resource: resourceNameFromProps,
resourceNameOrRouteName,
hideText = false,
accessControl,
- 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 ListButton
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
export const ListButton: React.FC<ListButtonProps> = ({
resource: resourceNameFromProps,
resourceNameOrRouteName,
hideText = false,
accessControl,
- 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 EditButton
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
export const EditButton: React.FC<EditButtonProps> = ({
resource: resourceNameFromProps,
resourceNameOrRouteName,
recordItemId,
hideText = false,
- 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 ShowButton
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
export const ShowButton: React.FC<ShowButtonProps> = ({
resource: resourceNameFromProps,
resourceNameOrRouteName,
recordItemId,
hideText = false,
- 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 CloneButton
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
export const CloneButton: React.FC<CloneButtonProps> = ({
resource: resourceNameFromProps,
resourceNameOrRouteName,
recordItemId,
hideText = false,
- 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 DeleteButton
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
export const DeleteButton: React.FC<DeleteButtonProps> = ({
resource: resourceNameFromProps,
resourceNameOrRouteName: propResourceNameOrRouteName,
recordItemId,
onSuccess,
- 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 checkAuthentication
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
export const checkAuthentication = async (
authProvider: LegacyAuthProvider,
request: Request,
redirectTo: string = new URL(request.url).pathname,
): Promise<any> => {
- 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 moveDeprecatedAccessControlProps
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
export const moveDeprecatedAccessControlProps = (
j: JSCodeshift,
source: Collection,
) => {
source.find(j.JSXElement).forEach((path) => {
- 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 ThemedHeader
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
export const ThemedHeader: React.FC<RefineThemedLayoutHeaderProps> = ({
isSiderOpen,
onToggleSiderClick,
toggleSiderIcon: toggleSiderIconFromProps,
}) => {
- 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 resourceFromInferred
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
export const resourceFromInferred = (
field: InferField | false | null,
resources: IResourceItem[],
): IResourceItem | undefined => {
if (!field) {
- 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"