Skip to content

Commit

Permalink
fix: use monaco uri paths instead of fs paths (#40)
Browse files Browse the repository at this point in the history
  • Loading branch information
j4k0xb committed Dec 30, 2023
1 parent e54edca commit 40d3eb0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions apps/playground/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ function App() {
models().filter((m) => m.uri.scheme === 'untitled'),
);
const filePaths = createMemo(() =>
fileModels().map((model) => model.uri.fsPath),
fileModels().map((model) => model.uri.path),
);

onCleanup(() => {
Expand All @@ -52,7 +52,7 @@ function App() {
}

function openFile(path: string) {
const model = fileModels().find((m) => m.uri.fsPath === '/' + path);
const model = fileModels().find((m) => m.uri.path === '/' + path);
if (!model) {
return console.warn(`No model found for path: ${path}`);
}
Expand Down

0 comments on commit 40d3eb0

Please sign in to comment.