如何在vscode里像typora那样插入图片?

如何在vscode里像typora那样插入图片?

实现效果

在vscode里实现typora的 Copy image to ./assets功能:

安装markdown image插件

Linux用户配置

Linux users must install xclip.

Ubuntu

sudo apt install xclip

CentOS

复制代码
sudo yum install epel-release.noarch
sudo yum install xclip

Remote Mode

If you want to use in the Remote Mode, please set remote.extensionKind like this:

json 复制代码
"remote.extensionKind": {
  "hancel.markdown-image": [
    "ui"
  ]
}

And if you want to save image in your remote workplace, you must use SFTP upload method. Local couldn't use in Remote Mode.

实际测试发现,remote模式下,需要配置remote.extensionKind,然后在remote的窗口中使用Local的配置即可。具体实现见下一节。

插件配置

❗️ 以remote模式为例。在local模式下配置方式相同。

文件名:img_${YY}${MM}${DD}-${HH}${mm}${ss}${mss}.png

复制代码
img_${YY}${MM}${DD}-${HH}${mm}${ss}${mss}

修改路径为:./assets

这样,在md中按快捷键alt+shift+v即可粘贴图片到./assets/...png。

转载需注明出处:CSDN Sylvan Ding

相关推荐
拼图2091 天前
VSCode 正则表达式使用指南
ide·vscode·正则表达式
小李不困还能学2 天前
VSCode_RemoteSSH_一直卡在下载服务器_解决教程
服务器·ide·vscode
lzj_pxxw5 天前
STM32移植FreeRTOS(Cmake+CubeMX)
vscode·stm32·嵌入式硬件
modelmd5 天前
离线安装与使用 vscode Remote SSH插件
ide·vscode·ssh
2501_9160088911 天前
iOS App 图标、启动屏和多语言搭配 方法,上架前使用KXBuild一次做好 App 图标
ide·vscode·ios·objective-c·个人开发·swift·敏捷流程
2501_9159184111 天前
iOS 推送通知怎么实现,从 APNs p8 密钥到 iOS 真机收到第一条推送
vscode·ios·objective-c·个人开发·swift·敏捷流程
sunshine22 girl12 天前
copilot vscode 使用技巧
人工智能·vscode·编辑器
2501_9159090612 天前
Windows 打开 Xcode 工程,编译调试 Xcode 项目并和 Mac 同事协作
ide·windows·vscode·macos·ios·个人开发·xcode
゛凌乱的记忆づ13 天前
好用的md文件编辑器——TyporaS与Typora
笔记·git·typora·markdown
2501_9160074713 天前
Windows OpenSSL 生成 iOS 证书,制作 p12 与描述文件,KXBuild 签名实操
windows·vscode·ios·objective-c·个人开发·swift·敏捷流程