gradio/js/sanitize/server.ts
Freddy Boulton 7134fc272e
Custom component fixes (#9711)
* add code

* Add code

* add changeset

* compatible lockfile

* add code

* add changeset

* trigger-ci

---------

Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>
Co-authored-by: pngwn <hello@pngwn.io>
2024-10-16 15:11:39 -07:00

6 lines
159 B
TypeScript

import { default as sanitize_html_ } from "sanitize-html";
export function sanitize(source: string, root: string): string {
return sanitize_html_(source);
}