如何让CSDN博客的代码高亮显示
我们在CSDN上写的代码默认效果是一片黑,白色字体
@Entity
public class DpOrder {
@Id
@GeneratedValue
private Integer id;
private String productType;
private String orderType;
System.out.println("hello world!");
}
代码高亮效果
@Entity
public class DpOrder {
@Id
@GeneratedValue
private Integer id;
private String productType;
private String orderType;
System.out.println("hello world!");
}
设置方法

在 “、、、”后面写上java,就表示是java语言了
c语言的话,直接写c
php语言的话,写php
c#比较特别,写csharp
目前支持代码类型: markup、html、svg、xml、c、clike、cpp、csharp、java、vbnet、go、ruby/rb、python/py、php、sql、perl、objectivec、swift、javascript/js、css、handlebars、bash、kotlin
如果觉得我的文章对您有用,请随意打赏。您的支持将鼓励我继续创作!



谢谢大家
本文来自博客园,作者:暗影月色程序猿,转载请注明原文链接:https://www.cnblogs.com/Geneling/p/15249238.html

浙公网安备 33010602011771号