Is there a HTML/CSS way to display HTML tags without parsing?

前端 未结 9 1109
忘了有多久
忘了有多久 2020-12-05 23:25

Is there any way that I could display HTML tags without parsing? Tags like XMP worked before perfectly but now it\'s replaced with PRE that isn\'t

9条回答
  •  野趣味
    野趣味 (楼主)
    2020-12-06 00:25

    And then... a few years go by, I have the same problem while converting my blog from wordpress to a vuejs spa backed by lambda and dynamodb.

    And the answer is; at least in my situation. Escape the entity.

    < becomes &lt;

    > becomes &gt;

    etc. etc.

    Hope this helps.

提交回复
热议问题