Skip to content

Commit 88ea28f

Browse files
authored
chore: Commit automatic lint fixes (#2819)
## Summary This PR commits the results of running `make dev-lint` after a lint rule was previously added to the ignore list for test files. This PR also reduces the limit on lint warnings in the app to the current number, after these fixes. ### Screenshots or video ### How to test on Vercel preview N/A - no behavior changes ### References - Linear Issue: - Related PRs:
1 parent 7779d2b commit 88ea28f

9 files changed

Lines changed: 16 additions & 16 deletions

‎packages/app/package.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
"build:clickhouse": "NEXT_PUBLIC_THEME=clickstack NEXT_PUBLIC_IS_LOCAL_MODE=true NEXT_PUBLIC_CLICKHOUSE_BUILD=true next build --webpack && node scripts/prepare-clickhouse-build-export.js",
1515
"run:clickhouse": "test -d out && npx rimraf tmp && mkdir tmp && cp -r out tmp/clickstack && echo 'visit http://localhost:3000/clickstack to start' && npx serve tmp -l 3000 || echo 'run build:clickhouse first'",
1616
"start": "next start",
17-
"lint": "npx eslint . --ext .ts,.tsx --max-warnings 740",
17+
"lint": "npx eslint . --ext .ts,.tsx --max-warnings 663",
1818
"lint:fix": "npx eslint . --ext .ts,.tsx --fix",
1919
"lint:styles": "stylelint **/*/*.{css,scss}",
2020
"ci:lint": "yarn lint && yarn tsc --noEmit && yarn lint:styles --quiet",

‎packages/app/src/__tests__/SessionSidePanel.test.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ jest.mock('nuqs', () => {
4040
const noop = () => {};
4141
return {
4242
...actual,
43-
// eslint-disable-next-line @eslint-react/no-unnecessary-use-prefix
43+
4444
useQueryState: (key: string, parser?: { defaultValue?: unknown }) =>
4545
key === 'sessionPanelEvent'
4646
? [mockNuqs.sessionPanelEvent, mockNuqs.setSessionPanelEvent]

‎packages/app/src/components/__tests__/DBRowSidePanel.missingSource.test.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ jest.mock('nuqs', () => {
2626
const actual = jest.requireActual('nuqs');
2727
return {
2828
...actual,
29-
// eslint-disable-next-line @eslint-react/no-unnecessary-use-prefix
29+
3030
useQueryState: (key: string, parser?: { defaultValue?: unknown }) => {
3131
const hasValue = Object.prototype.hasOwnProperty.call(
3232
mockQueryStore,

‎packages/app/src/components/__tests__/DBRowSidePanel.rememberedTab.test.tsx‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ const mockRow = {
6767

6868
jest.mock('../DBRowDataPanel', () => ({
6969
__esModule: true,
70-
// eslint-disable-next-line @eslint-react/no-unnecessary-use-prefix
70+
7171
useRowData: () => ({
7272
data: { data: [mockRow] },
7373
isLoading: false,
@@ -88,7 +88,7 @@ jest.mock('../DBRowDataPanel', () => ({
8888
jest.mock('@/source', () => ({
8989
__esModule: true,
9090
getEventBody: () => '__hdx_body',
91-
// eslint-disable-next-line @eslint-react/no-unnecessary-use-prefix
91+
9292
useSource: () => ({ data: undefined }),
9393
}));
9494

@@ -129,7 +129,7 @@ jest.mock('../ContextSidePanel', () => ({
129129

130130
jest.mock('../DBSessionPanel', () => ({
131131
__esModule: true,
132-
// eslint-disable-next-line @eslint-react/no-unnecessary-use-prefix
132+
133133
useSessionId: () => ({ rumSessionId: undefined, rumServiceName: undefined }),
134134
DBSessionPanel: () => null,
135135
}));

‎packages/app/src/components/__tests__/DBRowSidePanel.spanLinks.test.tsx‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ jest.mock('nuqs', () => {
2424
const actual = jest.requireActual('nuqs');
2525
return {
2626
...actual,
27-
// eslint-disable-next-line @eslint-react/no-unnecessary-use-prefix
27+
2828
useQueryState: (key: string, parser?: { defaultValue?: unknown }) => {
2929
const hasValue = Object.prototype.hasOwnProperty.call(
3030
mockQueryStore,
@@ -56,7 +56,7 @@ const LINK = {
5656
const mockUseRowData = jest.fn();
5757
jest.mock('../DBRowDataPanel', () => ({
5858
__esModule: true,
59-
// eslint-disable-next-line @eslint-react/no-unnecessary-use-prefix
59+
6060
useRowData: (args: unknown) => mockUseRowData(args),
6161
ROW_DATA_ALIASES: {
6262
DURATION_MS: '__hdx_duration',
@@ -82,14 +82,14 @@ const TRACE_SOURCE = {
8282
jest.mock('@/source', () => ({
8383
__esModule: true,
8484
getEventBody: () => undefined,
85-
// eslint-disable-next-line @eslint-react/no-unnecessary-use-prefix
85+
8686
useSource: ({ id }: { id: string | null }) =>
8787
id === 'trace-src' ? { data: TRACE_SOURCE } : { data: undefined },
8888
}));
8989

9090
jest.mock('../DBSessionPanel', () => ({
9191
__esModule: true,
92-
// eslint-disable-next-line @eslint-react/no-unnecessary-use-prefix
92+
9393
useSessionId: () => ({ rumSessionId: undefined, rumServiceName: undefined }),
9494
DBSessionPanel: () => null,
9595
}));

‎packages/app/src/components/__tests__/DBRowSidePanel.spanLinksBreadcrumb.test.tsx‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ const LINKED_SPAN_NAME = 'consume order.created';
3838
const mockUseRowData = jest.fn();
3939
jest.mock('../DBRowDataPanel', () => ({
4040
__esModule: true,
41-
// eslint-disable-next-line @eslint-react/no-unnecessary-use-prefix
41+
4242
useRowData: (args: unknown) => mockUseRowData(args),
4343
ROW_DATA_ALIASES: {
4444
DURATION_MS: '__hdx_duration',
@@ -62,14 +62,14 @@ const TRACE_SOURCE = {
6262
jest.mock('@/source', () => ({
6363
__esModule: true,
6464
getEventBody: () => undefined,
65-
// eslint-disable-next-line @eslint-react/no-unnecessary-use-prefix
65+
6666
useSource: ({ id }: { id: string | null }) =>
6767
id === 'trace-src' ? { data: TRACE_SOURCE } : { data: undefined },
6868
}));
6969

7070
jest.mock('../DBSessionPanel', () => ({
7171
__esModule: true,
72-
// eslint-disable-next-line @eslint-react/no-unnecessary-use-prefix
72+
7373
useSessionId: () => ({ rumSessionId: undefined, rumServiceName: undefined }),
7474
DBSessionPanel: () => null,
7575
}));

‎packages/app/src/components/__tests__/DBRowSidePanel.staleStack.test.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ jest.mock('nuqs', () => {
2626
const actual = jest.requireActual('nuqs');
2727
return {
2828
...actual,
29-
// eslint-disable-next-line @eslint-react/no-unnecessary-use-prefix
29+
3030
useQueryState: (key: string, parser?: { defaultValue?: unknown }) => {
3131
const hasValue = Object.prototype.hasOwnProperty.call(
3232
mockQueryStore,

‎packages/app/src/hooks/__tests__/useDashboardKioskMode.test.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ jest.mock('nuqs', () => {
66
const actual = jest.requireActual('nuqs');
77
return {
88
...actual,
9-
// eslint-disable-next-line @eslint-react/no-unnecessary-use-prefix
9+
1010
useQueryState: () => [false, mockSetKioskMode],
1111
};
1212
});

‎packages/app/src/hooks/__tests__/useSidePanelStack.test.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ jest.mock('nuqs', () => {
2424
const actual = jest.requireActual('nuqs');
2525
return {
2626
...actual,
27-
// eslint-disable-next-line @eslint-react/no-unnecessary-use-prefix
27+
2828
useQueryState: (key: string, parser?: { defaultValue?: unknown }) => {
2929
const hasValue = Object.prototype.hasOwnProperty.call(
3030
mockQueryStore,

0 commit comments

Comments
 (0)