eslint-plugin-sort-class-members
Advanced tools
Comparing version 1.18.0 to 1.19.0
@@ -25,2 +25,5 @@ "use strict"; | ||
}, | ||
sortInterfaces: { | ||
type: 'boolean' | ||
}, | ||
accessorPairPositioning: { | ||
@@ -27,0 +30,0 @@ "enum": ['getThenSet', 'setThenGet', 'together', 'any'] |
@@ -53,2 +53,3 @@ "use strict"; | ||
var stopAfterFirst = !!options.stopAfterFirstProblem; | ||
var sortInterfaces = !!options.sortInterfaces; | ||
var accessorPairPositioning = options.accessorPairPositioning || 'getThenSet'; | ||
@@ -134,2 +135,7 @@ var order = options.order || []; | ||
rules.ClassExpression = rules.ClassDeclaration; | ||
if (sortInterfaces) { | ||
rules.TSInterfaceDeclaration = rules.ClassDeclaration; | ||
} | ||
return rules; | ||
@@ -262,3 +268,3 @@ } | ||
if (node.type === 'ClassProperty' || node.type === 'ClassPrivateProperty' || node.type === 'PropertyDefinition' || node.type === 'PrivateIdentifier' || node.type === 'TSAbstractPropertyDefinition') { | ||
if (node.type === 'ClassProperty' || node.type === 'ClassPrivateProperty' || node.type === 'PropertyDefinition' || node.type === 'PrivateIdentifier' || node.type === 'TSAbstractPropertyDefinition' || node.type === 'TSPropertySignature') { | ||
type = 'property'; | ||
@@ -265,0 +271,0 @@ |
{ | ||
"name": "eslint-plugin-sort-class-members", | ||
"version": "1.18.0", | ||
"version": "1.19.0", | ||
"description": "ESLint rule for enforcing consistent ES6 class member order.", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
33966
691