5 lines
159 B
TypeScript
5 lines
159 B
TypeScript
const EM_DASH_PATTERN = /---/g;
|
|
|
|
export function typographicText(value: string | null | undefined) {
|
|
return (value ?? "").replace(EM_DASH_PATTERN, "—");
|
|
}
|