Home / Function/ unescape() — tailwindcss Function Reference

unescape() — tailwindcss Function Reference

Architecture documentation for the unescape() function in escape.ts from the tailwindcss codebase.

Entity Profile

Dependency Diagram

graph TD
  03501eb1_e642_df92_15b1_af590e3332fb["unescape()"]
  1ea8fd4a_634f_c2f0_5465_01d387d5207b["createThemeFn()"]
  1ea8fd4a_634f_c2f0_5465_01d387d5207b -->|calls| 03501eb1_e642_df92_15b1_af590e3332fb
  26086ff1_0d4f_fdb2_3fc4_d0c999f90a8c["parseCss()"]
  26086ff1_0d4f_fdb2_3fc4_d0c999f90a8c -->|calls| 03501eb1_e642_df92_15b1_af590e3332fb
  be7a0843_7490_00b8_ff59_a27552035f10["getOptions()"]
  be7a0843_7490_00b8_ff59_a27552035f10 -->|calls| 03501eb1_e642_df92_15b1_af590e3332fb
  f4b2481e_23ea_2f5c_fdf6_9834ac412e37["markUsedVariable()"]
  f4b2481e_23ea_2f5c_fdf6_9834ac412e37 -->|calls| 03501eb1_e642_df92_15b1_af590e3332fb
  style 03501eb1_e642_df92_15b1_af590e3332fb fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

packages/tailwindcss/src/utils/escape.ts lines 75–81

export function unescape(escaped: string) {
  return escaped.replace(/\\([\dA-Fa-f]{1,6}[\t\n\f\r ]?|[\S\s])/g, (match) => {
    return match.length > 2
      ? String.fromCodePoint(Number.parseInt(match.slice(1).trim(), 16))
      : match[1]
  })
}

Subdomains

Frequently Asked Questions

What does unescape() do?
unescape() is a function in the tailwindcss codebase.
What calls unescape()?
unescape() is called by 4 function(s): createThemeFn, getOptions, markUsedVariable, parseCss.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free