Files
tldr/pages.zh/windows/show-markdown.md

17 lines
572 B
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# Show-Markdown
> 以友好的方式在控制台中显示Markdown文件或字符串使用VT100转义序列或在浏览器中使用HTML。
> 注意此命令只能通过PowerShell使用。
> 更多信息:<https://learn.microsoft.com/powershell/module/microsoft.powershell.utility/show-markdown>。
- 从文件渲染Markdown到控制台
`Show-Markdown -Path {{path\to\file}}`
- 从字符串渲染Markdown到控制台
`"{{# Markdown content}}" | Show-Markdown`
- 在浏览器中打开Markdown文件
`Show-Markdown -Path {{path\to\file}} -UseBrowser`