chore: force refresh playground editor on startup
This commit is contained in:
parent
d1bf35c8b8
commit
3ac661b896
@ -55,9 +55,16 @@ onMounted(() => {
|
||||
editor.setOption('mode', props.mode)
|
||||
})
|
||||
|
||||
window.addEventListener('resize', debounce(() => {
|
||||
window.addEventListener(
|
||||
'resize',
|
||||
debounce(() => {
|
||||
editor.refresh()
|
||||
}))
|
||||
})
|
||||
)
|
||||
|
||||
setTimeout(() => {
|
||||
editor.refresh()
|
||||
}, 50)
|
||||
})
|
||||
</script>
|
||||
|
||||
@ -70,7 +77,7 @@ onMounted(() => {
|
||||
}
|
||||
|
||||
.CodeMirror {
|
||||
font-family: "Source Code Pro", monospace;
|
||||
font-family: 'Source Code Pro', monospace;
|
||||
height: 100%;
|
||||
}
|
||||
</style>
|
||||
|
Loading…
Reference in New Issue
Block a user