rescript-lang / rescript-lang/rescript-lang.org

Add keyboard shortcut for formatting and preserve cursor position

Open
#969 2 comments 0 reactions 1 assignee View on GitHub

@tsnobip is already working on this.

Since Feb 11, 2025.

playground
Dominant language
MDX
Stars
1.9k
Forks
260
Avg merge
3d 9h
Merged PRs (30d)
17

Description

Add a keyboard shortcut for formatting.

Currently, the cursor position gets lost after pressing it, which makes this feel very awkward. Try to preserve it.

This might only be solved by upgrading to CodeMirror 6 (https://codemirror.net/docs/migration/), which utilizes offsets instead of line coordinates.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.