mirror of
https://github.com/lennart-k/rustical.git
synced 2025-12-14 01:12:24 +00:00
frontend: Add xml escaping to collection creation forms
This commit is contained in:
@@ -0,0 +1,7 @@
|
||||
export function escapeXml(unsafe: string): string {
|
||||
return unsafe.replace(/&/g, '&')
|
||||
.replace(/</g, '<')
|
||||
.replace(/>/g, '>')
|
||||
.replace(/"/g, '"')
|
||||
.replace(/'/g, ''')
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user