chore: enable eslint rule react/no-danger (#17983)

* enable react/no-danger and disable rule all places

* remove wild rule
This commit is contained in:
Christoffer Bjelke authored and GitHub committed 2024-12-04 15:07:30 +00:00
1 parent 509fc4b289
commit a75a5b72b2
22 files changed
+43 -4

No files matched your search

+1
View File
@@ -21,6 +21,7 @@ export const Info = (props: {
return (
<p
className="dark:text-darkgray-600 mt-2 text-sm text-gray-500 [&_a]:text-blue-500 [&_a]:underline [&_a]:hover:text-blue-600"
// eslint-disable-next-line react/no-danger
dangerouslySetInnerHTML={{
__html: htmlContent
.replaceAll("<p>", `<p style="${css}">`)
@@ -1,5 +1,6 @@
/** @see https://gist.github.com/zomars/4c366a0118a5b7fb391529ab1f27527a */
const RawHtml = ({ html = "" }) => (
// eslint-disable-next-line react/no-danger
<script dangerouslySetInnerHTML={{ __html: `</script>${html}<script>` }} />
);