Skip to content

[member-ordering] separating readonly members is not supported #1063

Closed
@mustafa-cosar

Description

@mustafa-cosar

Hi, I want to separate readonly members from others. For example;

export class Class
{
    public static readonly A_CONSTANT = 56;
    public static readonly STRING_CONSTANT = "string";

    public static CLASS_MEMBER = "can be modified";

    public readonly anInstanceMember: string;

    public modifiableInstanceMember: string;
}

I couldn't find an option for readonly members in the documentation (https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/member-ordering.md)

Repro
N/A

{
  "rules": {
    '@typescript-eslint/member-ordering': 'error',
  }
}

Versions

package version
@typescript-eslint/eslint-plugin 2.3.2
@typescript-eslint/parser 2.3.2
TypeScript 3.6.3
ESLint 6.5.1
node 8.14.1
npm 6.11.3

Metadata

Metadata

Assignees

No one assigned

    Labels

    accepting prsGo ahead, send a pull request that resolves this issueenhancement: plugin rule optionNew rule option for an existing eslint-plugin rulepackage: eslint-pluginIssues related to @typescript-eslint/eslint-plugin

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions