You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
TypeScript projects will need to check the types in [v1.0.0](https://github.com/remarkablemark/html-react-parser/releases/tag/v1.0.0).
371
+
TypeScript projects will need to update the types in [v1.0.0](https://github.com/remarkablemark/html-react-parser/releases/tag/v1.0.0).
371
372
372
-
For `replace` option:
373
+
For the `replace` option, you may need to do the following:
373
374
374
375
```tsx
375
-
importparse, { Element } from'html-react-parser';
376
+
import { Element } from'domhandler/lib/node';
376
377
377
378
parse('<br class="remove">', {
378
379
replace: domNode=> {
@@ -446,7 +447,7 @@ See [#62](https://github.com/remarkablemark/html-react-parser/issues/62) and [ex
446
447
447
448
### TS Error: Property 'attribs' does not exist on type 'DOMNode'
448
449
449
-
The TypeScript error happens because `DOMNode` needs be an instance of domhandler's `Element`. See [migration](#migration) or [#199](https://github.com/remarkablemark/html-react-parser/issues/199).
450
+
The TypeScript error occurs because `DOMNode` needs be an instance of domhandler's `Element`. See [migration](#migration) or [#199](https://github.com/remarkablemark/html-react-parser/issues/199).
0 commit comments