'theme' is defined but never used
33 height: rem(16 * 1.25),
34 },
35 }),
36 badgeGroup: (theme) => ({37 root: {
38 height: rem(32),
39 },
'theme' is defined but never used
38 height: rem(32),
39 },
40 }),
41 textArea: (theme) => ({42 root: {
43 height: rem(120),
44 },
'StateSchema' is assigned a value but never used
72 s: z.string().array().optional().default([]).or(StringToArray),
73})
74
75const StateSchema = z.object({ 76 searchState: SearchStateSchema,
77 searchTerm: z.string().optional(),
78})
'ModalTitleBreadcrumb' is defined but never used
8 Breadcrumb,
9 type BreadcrumbProps,
10 isValidBreadcrumbProps,
11 type ModalTitleBreadcrumb,12} from '~ui/components/core/Breadcrumb'
13import { useCustomVariant } from '~ui/hooks'
14
'placeId' is defined but never used
212 }
213
214 const AutoCompleteItem = forwardRef<HTMLDivElement, AutocompleteItem>(
215 ({ label, fetching, placeId, ...others }: AutocompleteItem, ref) => {216 if (fetching)
217 return (
218 <div ref={ref} {...others} className={classes.itemComponent}>
'coordItems' is defined but never used
1import { z } from 'zod'
2
3import { coerceCoordItems, coordItems, pagination } from '~api/schemas/common' 4
5export const distSearch = z.object({
6 ...coerceCoordItems,
'isSuccess' is assigned a value but never used
58 ? queryParams.data
59 : (['dist', 0, 0, 0, 'mi'] as const)
60 const {
61 isSuccess, 62 isFetching: searchIsFetching,
63 ...searchQuery
64 } = api.organization.searchDistance.useQuery(
'getServerSession' is defined but never used
19
20import { ms } from '@weareinreach/api/lib/milliseconds'
21import { trpcServerClient } from '@weareinreach/api/trpc'
22import { getServerSession } from '@weareinreach/auth' 23import { Link } from '@weareinreach/ui/components/core/Link'
24import { UserReview } from '@weareinreach/ui/components/core/UserReview'
25import { CallOut } from '@weareinreach/ui/components/sections/CallOut'
'GetServerSidePropsContext' is defined but never used
12 useMantineTheme,
13} from '@mantine/core'
14import Autoplay from 'embla-carousel-autoplay'
15import { type GetServerSidePropsContext, type GetStaticProps } from 'next' 16import Head from 'next/head'
17import { type TFunction, Trans, useTranslation } from 'next-i18next'
18import { useRef, useState } from 'react'
Description
Unused variables are generally considered a code smell and should be avoided.
Removing unused references - It prevents unused modules from being loaded at runtime, improving performance, and preventing the compiler from loading metadata that will never be used. - It prevents conflicts that may occur when trying to reference another variable.
NOTE: If you have intentionally left a variable unused, we suggest you to prefix the variable name with a _
to prevent them from being flagged by DeepSource.
Bad Practice
import fs from 'fs' // <- unused
import { readFileSync } from 'fs'
const text = readFileSync('declaration_of_independence.txt', 'utf-8')
console.log(text)
Recommended
import { readFileSync } from 'fs'
const text = readFileSync('declaration_of_independence.txt', 'utf-8')
console.log(text)