Skip to main content
Module

x/gfm/deps.ts>htmlEscape

Server-side GitHub Flavored Markdown rendering for Deno
Latest
function htmlEscape
import { htmlEscape } from "https://deno.land/x/gfm@0.6.0/deps.ts";

Escape XML entities

This function takes a string of text and escapes it for use in text contexts in XML or HTML documents. Only the following characters are escaped: &, <, >, ", ', and `.

Parameters

text: string

Returns

string