Skip to content

Commit

Permalink
docs: use svelte ref
Browse files Browse the repository at this point in the history
  • Loading branch information
azat-io committed Dec 5, 2024
1 parent f564eb7 commit 187764c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docs/components/Editor/EditorMonaco.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
export let settings: Record<string, unknown> = {}
let editor: monaco.editor.IStandaloneCodeEditor | null = null
let container: HTMLElement | null = null
let baseValue = dedent`
import Button from '~/components/Button'
Expand Down Expand Up @@ -116,7 +117,6 @@
}
onMount(() => {
let container: HTMLElement | null = document.querySelector('.monaco')
if (container) {

Check failure on line 120 in docs/components/Editor/EditorMonaco.svelte

View workflow job for this annotation

GitHub Actions / JS

Unnecessary conditional, value is always falsy
defineMonacoTheme('css-variables')
Expand Down Expand Up @@ -175,7 +175,7 @@
})
</script>

<div class="monaco" />
<div bind:this={container} class="monaco" />

<style>
.monaco {
Expand Down

0 comments on commit 187764c

Please # to comment.