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

Commit

Permalink
Fix ts errors
Browse files Browse the repository at this point in the history
  • Loading branch information
Sebastian McKenzie committed Nov 14, 2022
1 parent 3840a9a commit 8a8dcaf
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 10 deletions.
4 changes: 1 addition & 3 deletions website/src/playground/Playground.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
import {
emptyPrettierOutput,
emptyRomeOutput,
import type {
PlaygroundProps,
RomeAstSyntacticData,
} from "./types";
Expand Down
1 change: 0 additions & 1 deletion website/src/playground/tabs/SettingsTab.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import {
IndentStyle,
PlaygroundSettings,
PlaygroundState,
QuoteProperties,
QuoteStyle,
Expand Down
5 changes: 2 additions & 3 deletions website/src/playground/workers/prettierWorker.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { formatWithPrettier } from "../utils";
import { formatWithPrettier, isTypeScriptFilename } from "../utils";
import { defaultPlaygroundState, PlaygroundSettings } from "../types";

let settings = defaultPlaygroundState.settings;
Expand All @@ -17,7 +17,6 @@ self.addEventListener("message", (e) => {
indentWidth,
quoteStyle,
quoteProperties,
typescript: isTypeScript,
trailingComma,
} = settings;
const code = e.data.code as string;
Expand All @@ -27,7 +26,7 @@ self.addEventListener("message", (e) => {
lineWidth,
indentStyle,
indentWidth,
language: isTypeScript ? "ts" : "js",
language: isTypeScriptFilename(filename) ? "ts" : "js",
quoteStyle,
quoteProperties,
trailingComma,
Expand Down
4 changes: 1 addition & 3 deletions website/src/playground/workers/romeWorker.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,9 @@ import {
IndentStyle,
LoadingState,
PlaygroundSettings,
PlaygroundState,
QuoteProperties,
QuoteStyle,
RomeOutput,
SourceType,
} from "../types";

let workspace: Workspace | null = null;
Expand All @@ -30,7 +28,7 @@ const files: Map<string, File> = new Map();

let configuration: undefined | Configuration;

function getPathForFile(file: File) {
function getPathForFile(file: File): RomePath {
return {
path: file.filename,
id: file.id,
Expand Down

0 comments on commit 8a8dcaf

Please sign in to comment.