Code Snippet 下载地址
下载后安装,重启windows live writer
插入——>CodeSnippet
将代码粘贴进去,如图:
代码效果:
@Controller
public class HelloWorld {
@RequestMapping("/HelloWorld")
public String hello() {
System.out.println("Hello World");
return "success";
}
}
Code Snippet有一个 silent 功能,点run silent 之后,直接CTRL+C代码,点一下Code Snippet就能快捷插入,但是好像没高亮效果,而且也不能在windows live writer 关闭这个silent功能。(/ □ )
只能在配置文件中关闭,搜素C盘CodeSnippet.dll.config 文件 然后进行修改 <RunSilent>false</RunSilent>