Showing 44 of 67 total issues
Function SetupRealtimeDatabaseFields
has 51 lines of code (exceeds 25 allowed). Consider refactoring. Open
function SetupRealtimeDatabaseFields(props) {
const { projectID } = props
const { changeStepCompletion } = useAppContext()
const {
updateValue,
Function SetupStorageFields
has 51 lines of code (exceeds 25 allowed). Consider refactoring. Open
function SetupStorageFields(props) {
const { projectID } = props
const { changeStepCompletion } = useAppContext()
const {
updateValue,
Function FieldCheckbox
has 51 lines of code (exceeds 25 allowed). Consider refactoring. Open
function FieldCheckbox(props) {
const {
className,
id,
isDisabled,
Function SetupRemoteConfigFields
has 51 lines of code (exceeds 25 allowed). Consider refactoring. Open
function SetupRemoteConfigFields(props) {
const { projectID } = props
const { changeStepCompletion } = useAppContext()
const {
updateValue,
Function ConfigureProjects
has 50 lines of code (exceeds 25 allowed). Consider refactoring. Open
export function ConfigureProjects() {
const {
data: { projects },
states: {
// areProjectsLoaded,
Function handleSubmit
has 49 lines of code (exceeds 25 allowed). Consider refactoring. Open
const handleSubmit = useCallback(async formState => {
const {
isValid,
values,
} = formState
Function mapOption
has 46 lines of code (exceeds 25 allowed). Consider refactoring. Open
const mapOption = useCallback(([optionValue, details]) => {
const {
component,
description,
label,
Function handleDeploymentReady
has 41 lines of code (exceeds 25 allowed). Consider refactoring. Open
async function handleDeploymentReady(payload) {
if (payload.target === 'production') {
const {
deployment: {
meta: {
Function reducer
has 40 lines of code (exceeds 25 allowed). Consider refactoring. Open
function reducer(state, action) {
const {
payload,
type,
} = action
Function mapDirectoryListing
has 35 lines of code (exceeds 25 allowed). Consider refactoring. Open
const mapDirectoryListing = useCallback(item => {
if (item.type === 'dir') {
return (
<Button
className="panel-block"
Function handler
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
export const handler = async (request, response) => {
const errors = []
if (!request.query['projectID']) {
return response.status(httpStatus.BAD_REQUEST).json({
Function vercelFetch
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
function vercelFetch(route, options) {
const parsedOptions = { ...options }
const defaultOptions = {
headers: {
Accept: 'application/json',
Function Button
has 29 lines of code (exceeds 25 allowed). Consider refactoring. Open
const Button = forwardRef((props, ref) => {
const {
children,
className,
isDisabled,
Function apiFetch
has 29 lines of code (exceeds 25 allowed). Consider refactoring. Open
async function apiFetch(route, options) {
const parsedOptions = { ...options }
const defaultOptions = {
headers: {
Accept: 'application/json',
Function GithubExplorer
has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring. Open
function GithubExplorer(props) {
const {
onSelect,
projectID,
title,
- 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 FieldColor
has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring. Open
function FieldColor(props) {
const {
className,
id,
isDisabled,
- 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 ProjectConfigurationForm
has 27 lines of code (exceeds 25 allowed). Consider refactoring. Open
function ProjectConfigurationForm(props) {
const { projectID } = props
const {
data: { projects },
} = useAppContext()
Function SelectServicesFields
has 27 lines of code (exceeds 25 allowed). Consider refactoring. Open
export function SelectServicesFields() {
return (
<>
<h3 className="heading">
{'Select which Firebase services you would like to have automatically deployed'}
Function handler
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
export const handler = async (request, response) => {
const errors = []
const responseJSON = {
accessToken: null,
projects: {},
- 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 ProjectConfiguration
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
function ProjectConfiguration(props) {
const {
projectID,
isOpen,
onClose,
- 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"