Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feature: add blank line in enums between constants & declarations #351

Conversation

clementdessoude
Copy link
Contributor

@clementdessoude clementdessoude commented Dec 30, 2019

Fix #309

In this PR, I always add a blank line before enumBodyDeclarations.

So we would get this formatting

// This input
public enum EnumWithExtraCommaAndEnumBodyDeclarations {
  THIS_IS_GOOD("abc"),
  THIS_IS_FINE("abc");
  public static final String thisWillBeDeleted = "DELETED";
}

// or this input
public enum EnumWithExtraCommaAndEnumBodyDeclarations {
  THIS_IS_GOOD("abc"),
  THIS_IS_FINE("abc");
  public static final String thisWillBeDeleted = "DELETED";
}

// will be formatted to this output
public enum EnumWithExtraCommaAndEnumBodyDeclarations {
  THIS_IS_GOOD("abc"),
  THIS_IS_FINE("abc");

  public static final String thisWillBeDeleted = "DELETED";
}

@clementdessoude clementdessoude changed the title feature: consistently add a blank line between enumConstantList and enumBodyDeclarations feature: add blank line in enums between constants & declarations Jan 1, 2020
@clementdessoude clementdessoude merged commit c5f012e into jhipster:master Jan 1, 2020
@clementdessoude clementdessoude deleted the feature/blank-line-enumBodyDeclarations branch January 1, 2020 15:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Blank line is removed in enum
1 participant