Skip to main content
The Deno 2 Release Candidate is here
Learn more
Module

x/frugal/docs/dep/he.ts>escape

A frugal web framework
Go to Latest
function escape
import { escape } from "https://deno.land/x/frugal@0.5.0/docs/dep/he.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