Skip to content

Conversation

@erickzhao
Copy link
Member

@erickzhao erickzhao commented Nov 15, 2025

A few changes in this PR:

  • All types-only imports changed from import to import type.
  • In order to align closer to the minimal-repro code formatting, I've wired up custom language formatters in main.ts where we first import Monaco. Unfortunately, the space before parens in function definitions is completely incompatible with Prettier, so we'll never get a perfectly clean unless we install StandardJS in the repo.
  • tabSize: 2 and insertSpaces: true are added upon editor instantiation (fixes CSS having 4-sized tabs by default).
  • Added a new Format All context menu option so that we can format all editors at once.

Future improvements:

@erickzhao erickzhao requested review from a team and codebytere as code owners November 15, 2025 00:54
@coveralls
Copy link

Coverage Status

coverage: 79.601% (-0.6%) from 80.234%
when pulling 91f9df3 on prettier-format
into 5e6b637 on main.

import { Button, Dialog, FileInput } from '@blueprintjs/core';
import { observer } from 'mobx-react';
import * as MonacoType from 'monaco-editor';
import type * as MonacoType from 'monaco-editor';
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

aside: do we care about doing import type for non-Monaco types as well? If so, it might be worth using @typescript-eslint/consistent-type-imports to automatically enforce this rule for all type imports (that would probably belong in a separate PR, though).

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I think it might be a good thing to add as a follow-up. IMO it makes it cleaner to separate the types-only imports vs. code imports.

@erickzhao erickzhao merged commit aeb3ed8 into main Nov 17, 2025
12 checks passed
@erickzhao erickzhao deleted the prettier-format branch November 17, 2025 19:51
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.

4 participants