{"library":"react-sanitizer-parser","type":"library","category":null,"description":"The `react-sanitizer-parser` package is a React component and utility library designed to safely render HTML content within React applications, mitigating XSS vulnerabilities. It acts as a convenient wrapper around two well-established libraries: `html-react-parser` for converting HTML strings into React elements and `DOMPurify` for robust HTML sanitization. As of version 0.1.4, it provides a `<ReactSanitizerParser>` component that takes a `dirty` HTML string as children, along with optional `htmlParserOptions` and `sanitizerConfig` props to fine-tune the behavior of its underlying dependencies. Additionally, it re-exports the `parse` function from `html-react-parser` and the `DOMPurify` object directly for more granular, imperative usage. Its primary differentiator is simplifying the integration of HTML parsing and sanitization into React, offering a streamlined API compared to configuring both libraries independently.","language":"javascript","status":"active","version":"0.1.4","tags":["javascript","react","parser","xss","sanitizer","html-react-parser","dompurify","DOMPurify","react-parser","typescript"],"install":[{"cmd":"npm install react-sanitizer-parser","imports":["import ReactSanitizerParser from 'react-sanitizer-parser';","import { parse } from 'react-sanitizer-parser';","import { DOMPurify } from 'react-sanitizer-parser';"]},{"cmd":"yarn add react-sanitizer-parser","imports":[]},{"cmd":"pnpm add react-sanitizer-parser","imports":[]}],"homepage":null,"github":"https://github.com/ssi02014/react-sanitizer-parser","docs":null,"changelog":null,"pypi":null,"npm":"https://www.npmjs.com/package/react-sanitizer-parser","openapi_spec":null,"status_page":null,"smithery":null,"compatibility":{"summary":{"python_range":"18–22","success_rate":0,"avg_install_s":null,"avg_import_s":null,"wheel_type":null},"url":"https://checklist.day/v1/registry/react-sanitizer-parser/compatibility"},"provenance":{"verified_status":null,"verified_at":null,"last_verified":"Wed Jun 17","next_check":"Sat Jul 18","install_tag":null}}