Interlace ESLint
ESLint Interlace
Import NextRules

no-default-export

Prevents default exports

šŸ’¼ This rule is enabled in the following configs: recommended, typescript. šŸ’” This rule is automatically fixable by the --fix CLI option.

Prevents default exports

Rule Details

This rule aims to prevent issues related to default-export.

Options

[
  {
    "type": "object",
    "properties": {
      "allowInFiles": {
        "type": "array",
        "items": {
          "type": "string"
        },
        "description": "Allow default exports in specific files."
      },
      "allowPatterns": {
        "type": "array",
        "items": {
          "type": "string"
        },
        "description": "Allow default exports for specific patterns."
      },
      "suggestNamed": {
        "type": "boolean",
        "default": true,
        "description": "Suggest named export alternative."
      }
    },
    "additionalProperties": false
  }
]

Implementation

OWASP Foundation

  • Category: A00:2021 - General Security

On this page