mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-29 05:15:04 +00:00
Run prettier on all files
This commit is contained in:
parent
3a405b65d6
commit
e26071d96e
23 changed files with 220 additions and 129 deletions
|
@ -3,21 +3,23 @@ import * as vscode from 'vscode';
|
|||
import { Server } from './server';
|
||||
|
||||
export class Config {
|
||||
public highlightingOn = true;
|
||||
public highlightingOn = true;
|
||||
|
||||
constructor() {
|
||||
vscode.workspace.onDidChangeConfiguration((_) => this.userConfigChanged());
|
||||
this.userConfigChanged();
|
||||
}
|
||||
|
||||
public userConfigChanged() {
|
||||
const config = vscode.workspace.getConfiguration('ra-lsp');
|
||||
if (config.has('highlightingOn')) {
|
||||
this.highlightingOn = config.get('highlightingOn') as boolean;
|
||||
constructor() {
|
||||
vscode.workspace.onDidChangeConfiguration(_ =>
|
||||
this.userConfigChanged()
|
||||
);
|
||||
this.userConfigChanged();
|
||||
}
|
||||
|
||||
if (!this.highlightingOn && Server) {
|
||||
Server.highlighter.removeHighlights();
|
||||
public userConfigChanged() {
|
||||
const config = vscode.workspace.getConfiguration('ra-lsp');
|
||||
if (config.has('highlightingOn')) {
|
||||
this.highlightingOn = config.get('highlightingOn') as boolean;
|
||||
}
|
||||
|
||||
if (!this.highlightingOn && Server) {
|
||||
Server.highlighter.removeHighlights();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue