message: chore(dev): make sure type checks and eslint can be really disabled
diff: @@ -17,11 +17,15 @@ export interface GetWithTypeCheckingParams {
  const getWithTypeChecking = ({ eslint, typeChecking, memoryLimit = 512 }: GetWithTypeCheckingParams) => (
  nextConfig: NextConfig,
  ) => {
  + if (!typeChecking && !eslint) {
  + return nextConfig
  + }
  +
  return addWebpackPlugin(
  nextConfig,
  new ForkTsCheckerWebpackPlugin({
  - typescript: typeChecking
  - ? {
  + typescript: {
  + enabled: typeChecking,
  memoryLimit,
  mode: 'write-references',
  diagnosticOptions: {
  @@ -30,17 +34,14 @@ const getWithTypeChecking = ({ eslint, typeChecking, memoryLimit = 512 }: GetWit
  semantic: true,
  syntactic: true,
  },
  - }
  - : undefined,
  + },
  - eslint: eslint
  - ? {
  - enabled: true,
  + eslint: {
  + enabled: eslint,
  memoryLimit,
  files: ['**/*.{js,jsx,ts,tsx}'],
  options: { cache: false },
  - }
  - : undefined,
  + },
  formatter: 'codeframe',
  }),
  