Skip to content

Commit 8a21b2a

Browse files
committed
chore: remove unused undefined union options
1 parent f4df34e commit 8a21b2a

File tree

5 files changed

+9
-11
lines changed

5 files changed

+9
-11
lines changed

apps/api-reference/src/components/Code/use-highlighted-code.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ const useHighlighter = () => {
4747
export const useHighlightedCode = (
4848
language: SupportedLanguage | undefined,
4949
code: string,
50-
dimRange?: readonly [OffsetOrPosition, OffsetOrPosition] | undefined,
50+
dimRange?: readonly [OffsetOrPosition, OffsetOrPosition],
5151
) => {
5252
const highlighter = useHighlighter();
5353
const decorations = useMemo(

apps/insights/src/components/PriceName/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ export const PriceName = ({ assetClass, uppercase, plural }: Props) =>
99
uppercase ? "upcase" : "title"
1010
];
1111

12-
const getLabels = (assetClass?: string | undefined) => {
12+
const getLabels = (assetClass?: string) => {
1313
if (assetClass === undefined) {
1414
return LABELS.ambiguous;
1515
} else {

apps/insights/src/hooks/use-query-param-filter-pagination.ts

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,11 @@ export const useQueryParamFilterPagination = <T>(
1616
items: T[],
1717
predicate: (item: T, term: string) => boolean,
1818
doSort: (a: T, b: T, descriptor: SortDescriptor) => number,
19-
options?:
20-
| {
21-
defaultPageSize?: number | undefined;
22-
defaultSort?: string | undefined;
23-
defaultDescending?: boolean;
24-
}
25-
| undefined,
19+
options?: {
20+
defaultPageSize?: number | undefined;
21+
defaultSort?: string | undefined;
22+
defaultDescending?: boolean;
23+
},
2624
) => {
2725
const logger = useLogger();
2826

apps/staking/src/api.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ export const loadData = async (
102102
client: PythStakingClient,
103103
pythnetClient: PythnetClient,
104104
hermesClient: HermesClient,
105-
stakeAccount?: PublicKey | undefined,
105+
stakeAccount?: PublicKey,
106106
simulationPayer?: PublicKey,
107107
): Promise<Data> =>
108108
stakeAccount === undefined

packages/component-library/src/Table/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -226,7 +226,7 @@ const cellProps = <T extends string>(
226226
ColumnConfig<T>,
227227
"alignment" | "width" | "fill" | "sticky" | "className"
228228
>,
229-
extraClassName?: string | undefined,
229+
extraClassName?: string,
230230
extraStyle?: CSSProperties,
231231
) => ({
232232
className: clsx(styles.cell, extraClassName, className),

0 commit comments

Comments
 (0)