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