Markdown preview autoreflash

Feature request for product/service

Cursor IDE

Describe the request

my test farmwork updates an markdown file, and since cursor has markdown preview function, hope it can auto update content/refalsh page when file gots updated

Operating System (if it applies)

Windows 10/11

Hi @steve_green!

Cursor should already work this way. Take a look at the screen recording below. Are you expericing something different?

idk why but looks this not work with my test farmwork sometime, guess theres some bug? maybe ya guys needs run a review for it..
looks like ya works on mac/linux, but im on windows, maybe this’s point?

```powershell
param(
    [string]$Path = (Join-Path $PSScriptRoot "live.md"),
    [int]$IntervalSeconds = 1
)

function U([uint32[]]$c) { -join ($c | ForEach-Object { [char]$_ }) }

$ErrorActionPreference = "Stop"
if ($IntervalSeconds -lt 1) { $IntervalSeconds = 1 }

$start = Get-Date
$tick = 0

Write-Host "$(U 0x5199,0x5165): $Path" -ForegroundColor Cyan
Write-Host "$(U 0x95F4,0x9694): ${IntervalSeconds}s  |  Ctrl+C $(U 0x505C,0x6B62)" -ForegroundColor DarkGray

try {
    while ($true) {
        $tick++
        $now = Get-Date
        $elapsed = $now - $start
        $barLen = [Math]::Min(50, $tick)
        $bar = ('=' * $barLen) + ('-' * (50 - $barLen))

        $content = @"
# Live Markdown

> $(U 0x6BCF,0x79D2,0x81EA,0x52A8,0x5237,0x65B0) $(U 0x00B7) $(U 0x7B2C) **$tick** $(U 0x6B21,0x66F4,0x65B0)

| $(U 0x5B57,0x6BB5) | $(U 0x503C) |
|------|-----|
| $(U 0x5F53,0x524D,0x65F6,0x95F4) | ``$($now.ToString('yyyy-MM-dd HH:mm:ss.fff'))`` |
| $(U 0x5DF2,0x8FD0,0x884C) | ``$([int]$elapsed.TotalHours):$($elapsed.ToString('mm\:ss'))`` |
| $(U 0x8FDB,0x7A0B) ID | ``$PID`` |
| $(U 0x4E3B,0x673A) | ``$env:COMPUTERNAME`` |

## $(U 0x8FDB,0x5EA6)

``````text
$([Math]::Min(100, $tick))%
$bar
``````

---

*generated by live-md.ps1*
"@

        [System.IO.File]::WriteAllText($Path, $content, [System.Text.UTF8Encoding]::new($false))
        Write-Host "`r[$($now.ToString('HH:mm:ss'))] tick $tick" -NoNewline
        Start-Sleep -Seconds $IntervalSeconds
    }
}
finally {
    Write-Host ""
    Write-Host "$(U 0x5DF2,0x505C,0x6B62,0xFF0C,0x6700,0x540E,0x5199,0x5165): $Path" -ForegroundColor Yellow
}
```

a

It looks like the file you’re changing has been deleted (see the strike-through of the filename in the upper left)? I have a feeling that might be the issue.

oh yeah thats the point, but maybe we can continue watch when file got been deleted and recreated?
and looks like I cant repo my test farmwork issue with shell script, but I can sure theres some issue with markdown autoreflash on windows `:(`

anyway thanks for you patientice, but I guees I dont wanna spent time on this since im disappointed for cursor, have a niceday `:)`