Skip to content
This repository was archived by the owner on Aug 31, 2023. It is now read-only.
This repository was archived by the owner on Aug 31, 2023. It is now read-only.

🐛 No formatting or lint errors with multiple empty lines #4785

Description

@talovsky

Environment information

rome rage   
CLI:
  Version:                      12.1.3
  Color support:                true

Platform:
  CPU Architecture:             x86_64
  OS:                           macos

Environment:
  ROME_LOG_DIR:                 unset
  NO_COLOR:                     unset
  TERM:                         "xterm-kitty"
  JS_RUNTIME_VERSION:           "v18.12.1"
  JS_RUNTIME_NAME:              "node"
  NODE_PACKAGE_MANAGER:         "null"

Rome Configuration:
  Status:                       Loaded successfully
  Formatter disabled:           false
  Linter disabled:              false
  Organize imports disabled:    true
  VCS disabled:                 true

Workspace:
  Open Documents:               0

Discovering running Rome servers...

Incompatible Rome Server: ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

ℹ Rage discovered this running server using an incompatible version of Rome.

Server:
  Version:                      <=10.0

What happened?

When I have multiple empty lines, they are not removed and no error is thrown. Example code:

export default function Error({ error }: { error: Error; reset: () => void }) {
  console.error(error);



  console.log('hi');

  return (
    <>

    
      <h1 style={{ color: 'red', backgroundColor: 'blue' }}>Error</h1>
      <NotfoundErrorPage />
    </>
  );
}

Expected result

I would like the formatter to remove them, and also, the linter to throw an error.

Code of Conduct

  • I agree to follow Rome's Code of Conduct

Activity

  1. added
    S-To triageStatus: user report of a possible bug that needs to be triaged
    on Aug 28, 2023
  2. ematipico commented on Aug 29, 2023

    @ematipico
    Contributor

    Could you:

    • tell us how you format/lint the code (CLI command, LSP, etc.)
    • share repository to reproduce the issue

    Also, the rage command says you're running an old server. What version of the extension are you running?

  3. added
    S-Needs infoStatus: the issue needs more info in order to be triaged
    and removed
    S-To triageStatus: user report of a possible bug that needs to be triaged
    on Aug 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    S-Needs infoStatus: the issue needs more info in order to be triaged

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions