(str: string)
| 110 | */ |
| 111 | // TODO: Test this method inside deconstructLine since it should not be used anywhere else |
| 112 | export function escapeForHtml(str: string): string { |
| 113 | return str |
| 114 | .slice(0) |
| 115 | .replace(/&/g, '&') |
| 116 | .replace(/</g, '<') |
| 117 | .replace(/>/g, '>') |
| 118 | .replace(/"/g, '"') |
| 119 | .replace(/'/g, ''') |
| 120 | .replace(/\//g, '/'); |
| 121 | } |
| 122 | |
| 123 | /** |
| 124 | * Deconstructs diff @line by separating the content from the prefix type |
no outgoing calls
no test coverage detected
searching dependent graphs…