Skip to content

Commit

Permalink
GAP-2521 | remove no-server-import-in-page eslint rule
Browse files Browse the repository at this point in the history
  • Loading branch information
ConorFayleAND committed Apr 23, 2024
1 parent a8c2007 commit 633302d
Show file tree
Hide file tree
Showing 12 changed files with 1 addition and 11 deletions.
1 change: 1 addition & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ module.exports = {
],
rules: {
'@typescript-eslint/no-non-null-assertion': 'off',
'@next/next/no-server-import-in-page': 'off',
},
},
],
Expand Down
1 change: 0 additions & 1 deletion packages/admin/src/middleware.page.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// eslint-disable-next-line @next/next/no-server-import-in-page
import { NextRequest, NextResponse, URLPattern } from 'next/server';
import { v4 } from 'uuid';
import { getLoginUrl, parseJwt } from './utils/general';
Expand Down
1 change: 0 additions & 1 deletion packages/admin/src/middleware.test.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import '@testing-library/jest-dom';
import { ResponseCookie } from 'next/dist/compiled/@edge-runtime/cookies';
// eslint-disable-next-line @next/next/no-server-import-in-page
import { NextRequest, NextResponse } from 'next/server';
import { NextURL } from 'next/dist/server/web/next-url';
import { middleware } from './middleware.page';
Expand Down
1 change: 0 additions & 1 deletion packages/admin/src/utils/csrfMiddleware/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// eslint-disable-next-line @next/next/no-server-import-in-page
import { NextRequest, NextResponse } from 'next/server';
import {
createSecret,
Expand Down
1 change: 0 additions & 1 deletion packages/admin/src/utils/csrfMiddleware/utils.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// eslint-disable-next-line @next/next/no-server-import-in-page
import type { NextRequest } from 'next/server';

export type TokenValueFunction = {
Expand Down
1 change: 0 additions & 1 deletion packages/admin/src/utils/logger.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable no-console */
// eslint-disable-next-line @next/next/no-server-import-in-page
import { NextRequest, NextResponse } from 'next/server';
import { GetServerSidePropsContext, NextApiRequest } from 'next';
import pino from 'pino';
Expand Down
1 change: 0 additions & 1 deletion packages/applicant/src/middleware.page.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import cookieParser from 'cookie-parser';
import { v4 } from 'uuid';
// eslint-disable-next-line @next/next/no-server-import-in-page
import { NextRequest, NextResponse, URLPattern } from 'next/server';
import { verifyToken } from './services/JwtService';
import { csrfMiddleware } from './utils/csrfMiddleware';
Expand Down
1 change: 0 additions & 1 deletion packages/applicant/src/middleware.test.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { middleware, buildMiddlewareResponse } from './middleware.page';
// eslint-disable-next-line @next/next/no-server-import-in-page
import { NextRequest } from 'next/server';
import { verifyToken } from './services/JwtService';
import { NextURL } from 'next/dist/server/web/next-url';
Expand Down
1 change: 0 additions & 1 deletion packages/applicant/src/utils/csrfMiddleware/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// eslint-disable-next-line @next/next/no-server-import-in-page
import { NextRequest, NextResponse } from 'next/server';
import {
getTokenFromRequest,
Expand Down
1 change: 0 additions & 1 deletion packages/applicant/src/utils/csrfMiddleware/utils.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// eslint-disable-next-line @next/next/no-server-import-in-page
import type { NextRequest } from 'next/server';

export type TokenValueFunction = {
Expand Down
1 change: 0 additions & 1 deletion packages/applicant/src/utils/jwt.test.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import { IncomingMessage } from 'http';
import { NextApiRequest } from 'next';
import { axiosConfig, getJwtFromCookies } from './jwt';
// eslint-disable-next-line @next/next/no-server-import-in-page
import cookieParser from 'cookie-parser';
import { NextApiRequestCookies } from 'next/dist/server/api-utils';

Expand Down
1 change: 0 additions & 1 deletion packages/applicant/src/utils/logger.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/* eslint-disable no-console */
// eslint-disable-next-line @next/next/no-server-import-in-page
import { NextRequest, NextResponse } from 'next/server';
import { GetServerSidePropsContext, NextApiRequest } from 'next';
import pino from 'pino';
Expand Down

0 comments on commit 633302d

Please sign in to comment.